Skip to main content

Full text of "TS-2068 Up-date"

See other formats


$4.95         OCTOBER  198^9 


EXPLORING  THE  POWER 


OF 


SINCLAIR  COMPUTERS 


THE  CAMBRIDGE  Z88 
Portable  Power 


y 


THE  SINCLAIR  QL 
32  Bit  Power  House 


THE  SINCLAIR  TIMEX  TS-2068 
Versatile  Desk  Topper 


In  this  issue.   .  . 

Automatic    Printer-    Control  Utilities 

The  June  1990  Milwaukee  Sinclair  Fest 
PLUS,  a  magazine  full  of  Programs  and  utilities 


UPDATE  MAGAZINE 

1317  Stratford  Ave. 
Panama  City,  FL  32404 
904  871  3556 


News  and  New  Products 


SYSTEMS 


3.5"  Drive  Systems 

Dual  3.5'  Mitsubishi  HOOK- 

This  great  little  system  includes  2-3.5" 
Mitsubishi  SSQO  drives,  case  w/ps,  cable 
w/ends  and  interface.  Complete  package! 
READY  TO  PLUG  AND  BO! 

ORDER  RMG8PI03  $  3  2  5  +  $ 8  PH 

Dual  3.5'  Teac  BOOK  System- 
includes  2  Teac  FD135  DSQD  drives,  case 
w/ps,  cable  &  interface.  HUGE  CAPACITY! 

ORDER  RHG8PI19  $ H 2 5 ♦  $ 8  PH 

Many  mora  packages  available! 
Just  call  or  write  with  what  you  want. 

Prices  start  at  only  *!??.?5  plus  PH. 

Individual  components  also  available. 


5.25"  Drive  System 

Dual  5.25"  8 0  0 K  System- 

This  system  comes  complete  with  the  disk 
interface,  dual  5.25"  DSQD  drives,  cable 

and  case  with  power  supply.  This  gives 
you  a  mass  storage  area  of  1,^0,000 
bytes  of  data  and  programming.  We  set  up 

and  test  EVERY  drive  set  that  we  sell! 

Alternate  Interface  s  • 

If  you  want  expanded  memory  with  your  QL 
disk  system,  we  can  supply  TRUMP  CARDS 
starting  as  low  as  $250  C256K).  Other 
sizes  available  upon  request* 
WRITE  FOR  INFO  OR  CATALOG   ($3 ) 


For_  ALL  of  your  computer ^need^  CALL- 

llMGr  BNTBRJPRIS 


1419  1/2  7th  Street 
Oregon  City,  OR  97045 


503/655-7484  Noon-iOPM  Pacific  Tue-Sat 


Editorials  and  tanouncements 
Update  QL  Editor 

Update  is  please  to  announce  that  Bill  Cable 
is  now  the  Sinclair  QL  EDITOR  for  Update  Magazine. 
As  most  subscribers  know,  Bill  Cable  is  a  foremost 
QL  Programmer  and  has  contributed  emensely  to  the 
content  of  the  magazine.  Now  Bill  will  be 
contributing  even  more.  Most  importantly,  we  now 
have  someone  who  will  maintain  accuracy  in  the 
articles  and  programs  for  the  QL.  Your  scribe  has 
been  uneasy  about  that,  given  his  novice  status 
with  the  QL.  Welcome  Bill  Cable,  and  thanks  for 
your  dedication  to  the  QL  Users  of  North  America. 

TS-2Q68  and  Z88  editing  will  continue  to  be 
handled  here  on  board  the  Update  Yacht.  Once  in  a 
while  we  may  be  a  couple  of  weeks  late,  as  the 
vessel  gets  laid  up  by  hurricanes  or  the 
doldrums.  Another  writer  for  the  Z88  has  come 
aboard.  Mike  Fink  (Domino  Cubes)  is  a  Z88  dealer 
that  has  gotten  rich  selling  Z88's  and 
periphreals.  Now  Mike  will  be  doing  a  regular 
column  in  Update  keeping  us  abreast  of  the 
happenings  with  this  nice  portable.  If  you  miss 
Syd  Wyncoop  in  this  issue,  not  to  worry.  Syd  DID 
send  in  an  article  but  Update  was  already  full  for 
October.    He'll  enjoy  that  one  in  the  next  issue. 

One  subscriber  wrote  saying  that  he  skims 
through  Update  for  "just  the  articles  about  his 
computer  and  its  disk  system".  Hell  heck!  He  is 
missing  out  on  the  educational  benefits  AND  the 
possibility  of  actually  using  the  programs  given 
for  the  "foreign  computer".  Most  programs  for  the 
QL,  TS-2068  and  Z88  can  be  kludged  to  work  with 
the  other.  BASIC  is  BASIC.  QL  Super  Basic,  BBC 
Basic,  and  TS-2068  Basic  are  but  variations  of  the 
same  language,  kinda  like  my  southern  drawl  and 
Pete  Hale's  Bostonian  twang.  This  issue  has  an 
article  by  Earl  Dunnington  that  illustrates  the 
point.  Earl  took  our  "LKDOS  Tool  by  the  Dozen" 
and  now  presents  the  same  tools  for  TOS  DISK. 
Another  Update  article  in  this  issue  "Printers  and 
Printer  Control"  is  generic  in  application  and  can 
be  cloned  in  any  computer's  syntax  and  variation 
of  Basic. 

Actually  both  the  QL  and  Z88  need  such  a 
printer  control  group  utility  to  augument  Quill 
and  Pipedream.  So,  Update  trys  to  give  as  many 
such  programs  and  utilities  to  Public  Domain  as  we 
can  for  the  use  of  all.  The  TS-2068  Disk  Drive 
users  need  not  wait  for  a  program  that  is  specific 
for  their  DOS.   All  TS-2068  programs  are  adaptable 


to  all  DOS,  with  minor  syntai  changes. 

Expanding  Cooperation 

Update  has  quietly  dropped  Commerical 
Advertising  in  favor  of  a  concept  of  Mutual 
Cooperation.  I  looked  back  two  years  and  found 
that  the  income  from  advertising  has  been  nil. 
Then  I  got  to  thinking.  Most  Dealers  are 
operating  as  a  Hobby,  or  at  such  low  key  that 
cannot  support  much  advertising.  Programmers  can 
spend  as  much  on  advertising  as  they  realize  from 
the  sales  that  the  ads  bring  in.  Subscribers  do 
need  to  be  exposed  to  SOURCE  information.  "Where 
can  I  find  a  whatsit  for  my  computer"?  We  ALL 
need  continuing  support.  So  Update's  diabolical 
new  scheme  is  to  provide  FREE  advertising  as  a 
cooperative  public  service.  The  way  it  is  put  to 
the  dealers  and  programmers  is:  "Think  of 
something  that  you  can  do  in  return  for  your  free 
ad". 

Examples:  Rod  Gowen  (RMG  Enterprises) 
includes  an  Update  Flier  in  his  catalog  mail  outs. 
Ed  Grey  (Ed  Grey  Enterprises)  posts  a  notice  for 
Update  in  his  BBS.  Peter  Hale  (EMSOFT)  and  Bill 
Cable  (Wood  And  Hind  Computers)  were  the  first  to 
join  into  the  scheme.  Mark  Stuber  (Sharps  Inc.) 
has  been  contacted  to  cooperate  in  similiar 
fashion.  Individual  programmers  may  not  have  much 
to  offer  in  return,  except  their  good  will,  which 
is  sufficient.  The  main  idea  is  to  provide  the 
most  support  possible  in  a  cooperative  effort. 

Publication  Situation 

THE  QUITS:  Now  that  other  publications  have 
pulled-  the  plug  I  get  quite  a  lot  of  questions 
about  the  future  of  Update  Magazine.  It  is  almost 
as  if  folks  are  thinking  "Update  is  next".  Well, 
all  that  I  can  say  is  that  Update  is  committed  for 
another  year  of  publishing-  BUT.  There  is  always 
that  qualifier,  eh?  The  publishing  of  Update  is  a 
hobby  for  me,  and  hobbies  can  become  entanglements 
that  interfere  with  other  life  needs,  such  as 
vacations,  etc.  AND,  everyone  is  subject  to  the 
burn  outs.  I  will  attempt  to  keep  Update  going 
indefinitely  by  throwing  out  this  gauntlet.  If 
YOU  are  dedicated  to  Sinclair  User  Support,  and 
have  the  ability  to  publish,  then  volenteer  to 
take  over  publishing  Update  at  some  time  in  the 
future.  That  wont  be  like  Ford  taking  over 
General  motors,  with  accompanying  stock  market 
rumbles.  It  will  be  an  easy  acquisition  and  a 
smooth  resumption.   Call  me. 


3. 


Update  Magazine 


October 


The  Cambridge  Z88 

Whither  goest? 

I  will  try  to  make  this  a  thoughtful  and 
honest  appraisal  of  the  Cambridge  88  Computer,  and 
how  I  see  its  future  developing.  First,  to 
compare  the  Z88  with  other  portable  computers  in 
its  price  range,  and  we  wont  go  into  a  lot  of 
figures  to  do  that.  The  Z88  compares  almost 
equally  to  the  Tandy  Portable  in  both  price  and 
capability.  Both  are  "8  bit  CPU"  computers,  which 
means  that  they  are  capable  of  managing  only  64K 
of  Memory  at  one  time.  This  also  means  that  - 
neither  computer  is  capable  of  being  "Compatable 
With  the  Operating  system  of  IBM  Computers  which 
is  "PC  Basic  and  MS-DOS".  The  operating  system 
for  both  the  IBM  and  the  Apple  Macintosh  are  for 
16  and  32  bit  CPU  operation.  So  we  must  first 
explode  this  myth  that  seems  to  he  developing. 
The  Z88  IS  NOT  IBM  or  MACINTOSH  COMPATABLE.  NONE 
OF  THE  SOFTWARE  FOR  IBM  or  MACINTOSH  COMPUTERS 
WILL  WORK  WITH  THE  Z88  or  the  TANDY  PORTABLE. 

Speaking  of  CAPABILITY,  and  comparing 
Capability  with  other  computers,  the  Z88  compares 
with  the  TS-2068,  the  Sinclair  Spectrum,  the 
Commodore  128,   and  other  8  bit  computer 

systems.  All  comparisons  with  those  computers 
will  result  in  the  Z88  showing  superiority  in  all 
areas  except  Screen  Dislay  and  Interface  to 
outside  devices.  The  latter  is  a  serious  handicap 
with  the  Z88,  but  there  has  been  a  recently 
developed  Portable  Disk  drive  which  mitigates  that 
problem.  The  screen  display  is  a  problem  yet  to 
be  resolved  with  both  the  Z88  and  its  counterpart, 
the  Tandy  Portable. 

Now  lets  turn  to  the  COST  factor.  Just  how 
much  the  III  can  be  purchased  tor  depends  upon  the 
deal  that  you  can  get  from  your  dealer.  My  Z88, 
equipped  with  a  128R  RAM  cartridge,  a  32K  EPROM 
Cartridge,  the  PC  LINK  Eprom,  and  carrying  case, 
cost  around  $700.  A  Commodore  C-128,  equipped 
with  a  disk  drive  and  Monitor  will  cost  slightly 
higher.  I  had  a  C-128  once  and  didn't  like  it  at 
all.  The  Z88  has  much  more  capability  for 
managing  extra  Memory  and  has  more  overall 
computing  capability.  But  the  C-128  has  the 
advantage  of  better  display  and  a  well  established 
library  of  commercial  software. 

But  we  have  been  discussing  and  comparing  a 
"desk  top  computer  with  a  portable".  Should  we? 
Is  there  a  difference  in  the  Computing  needs  that 
one  has  if  one  needs  a  Portable?  I  think  not. 


The  Computer  industry  tends  to  agree.  Portables 
are  now  being  offered  that  are  IBM  MS-DOS 
compatable.  So   lets   look  at   one   line  of 

portables.  A  current  Computer  Shopper  ad  shows  a 
Toshiba  T-1000  that  can  be  a  comparison.  This  one 
is  an  IBM  Compatable  that  runs  MS-DOS  programs. 
Its  fold-up  LED  display  is  larger  than  the  Z88's 
display,  and  it  has  a  built-in  720K  Disk  drive. 
The  Toshiba  1000  also  has  512K  of  RAM  installed. 
The  advertised  price  is  $649.95.  I  wont  comment 
upon  how  good  or  bad  the  Toshiba  1000  may  or  may 
not  be.  It  is  Tosyiba's  "low  end"  portable. 
Toshiba's  other  portables  run  up  to  $5000  in 
price.  There  are  other  portables  that  are  IBM 
compatables  whose  price  range  could  form  a  basis 
for  comparison  with  the  Z88. 

Enough  Comparing!  Lets  see  what  the  Z88's 
real  attributes  are.  And,  I  might  say  that 
Cambridge  North  America  is  not  pushing  the  real 
attributes  of  the  Z88.  Instead  they  seem  to  be 
hyping  the  ability  to  transfer  ASCII  Files  back 
and  forth  between  the  Z88  and  IBM  computers.  That 
Isn't  "IBM  COMPATABILITY".  It  is  instead  a 
"Software  Innovation",  that  is  commonly  done  every 
day  with  Telecom  (Modem)  software.  The  real 
attributes  of  the  Z88  is  in  its  operating  system 
that  can  easily  address  up  to  One  Megabyte  of 
Extra  Memory.  This  capability,  which  is 
un-matched  by  any  existing  8  bit  computer,  has  not 
been  emphasised  in  the  marketing  efforts  by 
Cambridge  North  America.  They  seem  to  be  un-aware 
of  the  main  attributes  of  the  Z88  and  are  chasing 
a  rainbow  in  the  "IBM  Compatability"  forest. 

Let  us  visualize  that  we  all  have  IBM 
computers.  You  might  be  a  travelling  salesman  and 
need  a  Portable  Computer.  Would  you  spend  $6-800 
to  buy  a  Z88,  knowing  that  it  cannot  run  the 
library  ot  software  that  you  have  tor  your  1BH? 
Well,  maybe  the  ability  to  transfer  data  files 
between  the  two  computers  might  be  worth  the 
price?  But  no,  you  can  get  that  .low  end  Toshiba 
for  about  the  same  price,  eh?  And  it  can  run  your 
IBM  software. 

The  Z88's  competitive  position  seems  to  be 
right  there  with  the  "low  end"  computers  like  the 
Commodore  128  and  Spectrum.  But  to  be  competitive 
there  the  Z88  needs  better  support  by  Sinclair 
Research  and  Cambridge  North  America.  Needed  are: 
Interfaces  to  Disk  Drive,  Interfaces  to  a  desk  top 
Monitor,  and  Software.  While  the  two  built-in 
softwares  "Pipedream  and  Diary"  are  excellent, 
they  hardly  suffice  as  a  complete  computer  system 
library.   Such  support  would  turn  the  Z88  from  its 


Octob*"  1989 


Update  Magazine 


Update  Magazine 


October  labtf 


single  purpose  as  a  portable  to  both  a  portable 
and  a  desk  top  system,  and  could  blow  Commodore 
out  of  the  low  end  computer  market. 

So,  to  evaluate  the  future  of  the  Z88  in  the 
North  American  market,  we  must  speculate  about  the 
INTENT  of  Sinclair  Research  and  their  American 
representative,  Cambridge  North  America. 

Update  Magazine  began  seeking  cooperation 
from  Cambridge  North  America  before  Christmas  of 
1988.  A  number  of  letters  since  have  requested 
regular  news  releases  of  technical  information, 
programming  information,  and  general  user  support 
information.  Copies  of  Update  magazine  have  been 
sent  to  them.  As  of  this  time  Cambridge  North 
America  has  not  cooperated  at  all.  Though  a  small 
publication,  Update  Magazine  is  the  only 
publication  in  North  America  that  is  willing  to 
provide  on-going  Z88  User  Support.  This  could 
help  Cambridge  North  America  in  their  marketing 
efforts  by  the  building  up  of  a  data  base  about 
the  Z88  and  creating  interest  in  the  Z88. 
Satisfied  and  enthusiastic  users  become  the  best 
advertising,  and  money  cannot  buy  that. 

That  Cambridge  North  America  would  completely 
spurn  and  ignore  our  efforts,  which  would 
certainly  be  of  benefit  to  them,  is  both  enigmatic 
and  ignominious.  The  only  conclusion  that  can  be 
drawn  is  that  there  is  no  interest  on  their  part 
in  USER  SUPPORT,  nor  in  building  a  reliable 
reputation  in  the  North  American  market  place.  If 
Cambridge  North  America  begins  to  show  more 
interest  in  user  support  we  will  certainly  credit 
them  with  a  change  in  attitude  and  will  welcome 
their  participation.  There  is  really  no  reason 
why  they  shouldn't.  What  is  the  cost  of  a  few 
pieces  of  paper  mailed  out  periodically  to  a 
magazine?  If  this  article  makes  you  a  bit  miffed, 
write  them  a  letter  and  invite  them  to  help  us  to 
help  them. 

Z88  Operating  Tips 

In  August,  my  Son  Greg  took  a  liking  to  my 
Z88.  Greg  is  in  his  final  semester  and  will 
graduate  this  fall  with  degrees  in, Finance  and 
Business  Management  (Florida  State  University). 
Anybody  out  there  need  a  good  man?  Now  Greg 
already  had  the  IBM  AT  computer  that  I've  been 
knocking  for  the  past  couple  of  years.  The  IBM  is 
set  up  in  our  Motor  Home  near  the  college,  which 
is  100  miles  East.  Maybe  Til  get  the  MH  back  in 
time  to  go  to  the  Milwaukee  Computer  Fest?  So,  I 
made  a  deal  with  fl  Son.  He  can  keep  the  Z88  for 


the  semester  if  he'll  contribute  some  "HOW  TO" 
articles  for  Update  Magazine.  To  start  him  off 
right  I  assembled  a  manual  of  sorts  gleaned  from 
EPROM,  the  defunct  "News  Notes",  and  from  Mike 
Fink  (Domino  Cubes).  The  assemblage  made  a  good 
addition  to  the  Z88  manual  which  comes  up  short  is 
some  respects. 

Greg  suprised  me  the  second  day.  He  had 
worked  up  a  resume  with  the  Z88  and  was  ready  to 
print  it.  He  came  in  and  used  the  Update  Daisy 
Wheel  printer  to  print  the  resume.  The  print-out 
was  formatted  well  and  looked  nice.  Not  bad  for 
two  days  usage  of  a  new  computer,  eh?  Then  he 
left  for  college  the  next  day.  His  article 
follows. 


WORD  PERFECT  POWER  WITH  THE  Z88 

By:  Greg  Jones 

Sounded  too  good  to  be  true,  so  I  followed  the 
directions  given  by  Bob  Curry,  and  those  given  in 
the  Manual  for  "PC  LINK".  It  works  like  a  charm! 
I  was  able  to  begin  a  document  at  home  with  the 
288,  then  when  I  returned  to  Tallahasse,  the 
document  was  fed  into  my  IBM  with  PC  LINK,  and  the 
finishing  touches  was  done  with  the  IBM  software 
WP-50.  The  power  of  Word  Perfect's  thesarus,  spell 
checker,  and  formatting,  became  available  with  the 
IBM.  Freedom  of  movement  is  available  with  the 
Z88.  The  combination  of  Portability  and  the  extra 
power  of  Word  Perfect  is  hard  to  beat.  Then  there 
is  the  unlimited  file  storage  of  the  IBM's  hard 
disk  to  add  to  the  flexibility.  Following  is  a 
step  by  step  guide  for  how  to  transfer  files  back 
and  forth  between  the  Z88  and  the  IBM. 

1.  Create  your  text  with  the  Z88.   It  is  best  to 
start  with  something  short. 

2.  SAVE  your  file  to  the  Z88  Ram  Memory,  using  Menu 
*3,  then  arrow  to  SAVE  and  NAME  your  Text. 

3.  Now  you  are  ready  to  connect  up  the  two 
computers . 

a.  Key  INDEX  on  the  Z88 

b.  Insert  PC  LINK  EPROM.   Close  Cartridge  door. 
Connect  Z88  and  PC  with  cable. 

c.  Arrow  Down  to  LINK 

4.  Get  into  your  PC-LINK  directory  with  your  hard 
Drive  (The  PC  LINK  Floppy  disk  was  saved  to 
the  hard  drive  previously.)  Type  PCLINK.  lou 
will  then  be  prompted  to  run  your  Link  Program 
with  the  Z88.  Key  the  Link  program  in  the 
Index  Directory  of  the  Z88.  This  assumes  that 
you  have  already  installed  PC-LINK  as  is 


October  1989 


5 


Update  Magazine 


Update  Magazine 


oclober  lliiil) 


directed  by  page  2-4  of  the  Link  Guide. 

5.  Hit  RETURN  on  your  PC  Computer. 

6.  Screen  II  found  on  page  10  of  the  guide  will 
appear. 

7.  QUIT    Z88  Devices     Z88  Dirs     Z88  Files 

8.  HELP    PC  Devices      PC  Dirs      PC  Files 

I  am  using  a  128K  Ram  Cartridge  in  slot  11,  so  I 
change  my  default  devices  to  RAH  .01.  The  Z88  Dirs 
is  simply  your  default  directory,  which  in  my  case 
is  Ram  .01.  The  PC  Devices  in  my  case  is  my  hard 
drive  and  my  PC  dirs  is  my  PC-LINK  Directory.  As  I 
want  to  send  this  file  to  my  PC  Computer,  I  select 
Z88  Files  at  the  first  menu. 

Then  I  am  prompted  "Send  to  PC"  Key  RETURN. 
Program  shows  me:  C:\pclink\filename  Key  RETURN. 
Then   there  is  a  little  graphics  display  that  shows 
that  your  file  is  actually  transferring  to  the  PC. 
Once  finished  you  get  out  of  the  PC-LINK  Program. 

9.  Now  you  transfer  the  new  file  to  WordStar 
Format.  On  your  PC,  type  PTH.  This  is  the 
converter  program.  You  will  be  prompted  to  name 
the  file  type  and  the  file  name,  with  extension. 
Then  further  prompt  for  "Name  want  to  convert  to?". 
Call  it  something  slightly  different  and  hit 
RETURN.  Now  transfer  into  your  Word  Perfect 
program. 

10.  a.  Key  Shift  +  F10,  then  give  path  name,  plus 
the  file  name.  In  my  case  this  is:  C:\PCLINK\file 
name,  and  hit  RETURN. 

b.  Shift  +  F8;  1  :  7  ;  then  change  both 
margins  to  .5  and  key  RETURN  until  you  get  back  to 
text,  then  hit  page  down  and  the  document  that 
your  started  in  the  Z88  PipeDream  will  be  ready  to 
finish  using  your  Word  Perfect  Program. 

The  procedure  to  get  back  to  PipeDream  is  not  so 

1.  SAVE  as  DOS  Text  by  using  Control  +  F5. 

2.  Get  out  of  Word  Perfect  and  back  to  your  PC-Link 
Directory.  Make  sure  that  the  two  computers  are 
hooked  up  correctly.  Thentype  PCL1NK.  The  program 
will  prompt  you  to  make  sure  that  your  Link  program 
is  running. 

3.  Make  sure  that  your  Z88  Devices  are  still 
correct.  (Mine  went  back  to  RAM  0,  and  I  wanted 
RAM  .01.) 

4.  Select  PC-Files.  Highlight  the  file  wanted. 
You  will  be  prompted  to  send  to  the  Z88,  and  once 
you  hit  RETURN  the  graphics  display  will  show  that 
the  file  is  transferring. 


5.  Go  to  the  Menu  Files  Option  and  load  the  newly 
sent  file.  In  my  case  the  file  loads  but  I  can 
only  see  the  first  fifth  of  a  sentence.  I  used  the 
star  +  W  option  and  set  column  to  72,  and  then  I 
could  see  the  entire  document.  There  may  be  a 
better  way  but  this  works  for  me. 

So  far  I  have. not  found  a  way  to  get  a  spread  sheet 
to  transfer.  I  am  using  TWIN,  which  is  advertised 
as  being  100%  compatable  with  LOTUS.  When  I  try  to 
use  LOTUS  to  Pipe  Dream,  it  kicks  back  "NOT  a  Valid 
Lotus  Program".  If  anyone  has  an  answer  to  this,  I 
would  welcome  the  information.   Greg  Jones. 


October  19E^ 


bp<5at«5  Magazine 


Update  Magazine 


October  1989 


QL+MSDOS 
Oick  F-  Wagner 

The  ability  to  access  the  many  MSDOS  programs  is  enticing.  A 
look  thru  catalogs  of  3  West  Coast  dealers  in  MSDOS  Shareware 
programs  certainly  proves  the  point  of  the  availability  of  a 
vast  range  of  programs  at  very  reasonable  prices.    In  quantities 
of  less  than  10  disks  the  prices  run  about  *3.25-»4.00.  Some 
large  programs  require  2-3  disks.   Remember,   Shareware  involves 
additional  payment  in  some  cases  if  the  program  is  satisfactory, 
but  not  an  excessive  surcharge  (the  original  payment  is  to  the 
company,  none  goes  to  the  programmer). 

The  catalogs  provide  good  descriptions  and  sometimes  indicate 
the  additional  amount  of  memory  required  for  an  IBM  PC  type 
computer. 

Having  this  information,   is  an  IBM  PC  MSDOS  type  program 
practical   in  an  emulator   form?  Once  the  cost  of  additional 
memory,   disk  driver  hardware,   a  printer  interface,   and  some  kind 
of  a  "tool  kit"  program  is  written  off,   then  the  investment  is 
for  a  program  to  emulate  MSDOS,   plus  MSDOS  itself  if  it  is  not 
in  your  mix  of  programs.  The  cost  seems  high  if  MSDOS  must  be 
purchased.  The  "chocalate"  version  includes  version  4.0  and  a 
set  of  manuals,   along  with  the  basic  emulator,    "SOLUTION"  and 
its  manual.  The  "vanilla"  version  is  the  emulator  and  manual 
only. 

It  should  be  noted  that  the  emulator  manual  makes  no  effort  to 
discuss  MSDOS  programming,  except  enough  to  get  the  MSDOS 
program  loaded.  The  user  must  get  manuals,  books,  school 
classes,  etc.  to  actually  use  MSDOS.     Provision  is  made  in 
"SOLUTION"  to  use  the  dedicated  F1-F10  common  to  MSDOS  by 
providing  other  key  stroke  combinations. 

The  user  must  have  additional  memory  for  the  QL  as  the  first 
added  bank  of  256K  will  Just  get  by  with  MSDOS  plus  a  single 
disk  program  if  not  too  long.  When  considering  longer  programs 
like  spreadsheets  and  wordprocessors,  a  second  bank  of  256K  will 
be  needed  unless  working  with  really  elaborate  programs  in  which 
case,  a  fully  populated  board  with  768K  would  be  required. 

An  MSDOS  emulator  program  makes  the  mother  computer   (QL  for 
instance)  think  it  is  an  IBM  PC  type  computer  J    It  takes  two 
programs  to  accomplish  this  emulation.  The  first,  called 
"SOLUTION"  by  Digital  Precision,   is  loaded  into  the  computer 
memory.   It  does  all  of  the  converting  from  the  IBM  PC  CPU  type 
commands  to  the  QL  CPU  Super basic  type  commands.  The  second 
program  is  MSDOS  itself.   It  is  kind  of  like  running  2  programs 
in  series  back  and  forth. 

Because  of  the  reduced  speed  of  an  emulator   (about  1/10  of  a  PC) 
I  am  using  an  accelerator  called  "LIGHTNING"  which  almost  gives 
normal  PC  speed.  My  procedure  for  getting  MSDOS  into  operation 
is  to  load  "LIGHTNING",  then  the  tool  kit   (TK2)  is  initialized, 
next  "SOLUTION"  is  loaded,  and  finally  MSDOS. 

There  seem  to  be  several  emulators  on  the  English  market. 
Digital  Precision  has  had  experience  with  a  CP/M  emulator,  plus 


Z 

October  1989  Update  Magazine 


one  for  the  Atari  computers.   Reviews  in  English  magazines  seem 
to  show  a  preferance  for  the  DP  system  as  being  the  most 
complete  and  reliable.   Sources  in  the  US  include  RMG 
Enterprises,    1419  1/2     7th  St.   Oregon  Cityr   OR  97045,  and 
SHARP'S  Inc.   Box  326,   Mechanicsvi 1 le,   VA  23111. 

So  far  my  biggest  objection  to  the  operation  of  "SOLUTION"  is 
the  need,   when  in  MSDOS,   to  start  all  over  again  with  a  computer 
reset  when  a  MSDOS  type  program  hangs  up.  .Maybe  that  will  be 
reduced  with  experience  with  the  system  and  maybe  there  is 
something  in  the  "SOLUTION"  manual  or  in  the  MSDOS  manual  that 
gives  a  clue  for  solving  this.  As  usual,  there  is  an  extended 
learning  process  required  when  switching  computer  operating 
systems. 


QL  TO  Z88  LINKUP 
Bill  Woodward 


The  QZ  comes  with  all  Instructions  on  a  mdv  cartridge  and  a  10  foot 
connecting  cable.  The  cable  has  two  different  style  end  D  rings,  so  only  one 
style  can  fit  in  the  Z88's  D  ring.  The  larger  one  goes  in  the  QL's  serial 
port.  The  instructions  (contained  in  README2_doc)  say  Ser2,  but  my  cable 
package  had  Serl  printed  on  it.  First  BUG:  the  QZ  would  not  transfer  with 
the  plugin  in  either  port.  I  found  the  answer  in  P  Panel (change  defaults 
etc)  on  the  MENU.  I  change  the  default  SBR2  to  SBR1  and  the  QZ  performed  its 
act  well.  When  I  have  a  problem  I  go  to  the  instructions  first  and  to  the  P 
Panel  for  the  default  devices.  All  of  my  problems  have  resulted  from  my  one 
tract  mind. 

The  program  can  be  backed-up  to  either  MDV  or  FLP.  Unless  you  know  how  to 
combine  the  RBSPR's  of  the  programs  QZ  cannot  be  multitasked  with  another 
program.  Before  you  run  the  program  hard  copy  the  instructions  by  loading 
RBADME2  into  Quill  and  printing.  Then  you  can  run  the  program  turn  on  or 
reset.  The  instructions  and  on  screen  MENU  OPTIONS  are  easily  understood. 
Even  I  was  able  to  transfer  a  file  from  Z88  to  QL  disks  after  a  small 
difficulty. 


The  MENU  OPTIONS  are: 


S  Send  a  file  from  QL  to  Z88 

R  Read  a  file  from  268  to  QL 

B  Batch  receive  files  from  the  Z88 

D  Directory  of  a  device 

E  Send  endbatch  code 

F  Rename  a  file 

K  Kill  a  file 

V  View  a  file 

P  Panel   (change  default  etc) 

Q  Quit  to  basic 

T  Translate  carriage  returns 

Transferring  a  Quill  document  to  Plpedream 

Transferring  a  Plpedream  document  to  Quill 


The  transferring  of  a  Plpedream  document  to  Quill  will  let  you  use  the  Z88 
portable  and  when  you  return  to  your  home  base  you  can  transfer  the  document 
to  Quill  and  continue  to  work  on  It  on  the  large  screen  of  your  monitor. 
If  you  are  using  a  serial  printer,  the  QL  serial  cord  will  not  work,  but  the 
Z88  printer  cord  will  let  you  plug  into  the  serial  printer  and  print  out 
with  out  going  through  Quill. 


Update  Mmm'Aim 


Update  Magazine 


October  1989 


Printing  and  Formating 

Commanding  the  Printer 

This  is  one  of  many  selected  Daisy. B6  program 
routines  that  will  be  excerpted  and  given  to 
Public  Domain.  These  routines  will  be  selected 
for  their  generic  value.  This  one  provides 
PRINTER  CONTROL.  The  need  was  perceived  to 
Command  the  printer  to  CHANGE  PRINT  STYLES  to  do  a 
LARGE  CENTERED  CAPTION,  then  to  RESET  to  the 
original  style.   But  it  does  more  that  that. 

We  enter  the  routines  with  some  established 
Variables.  PS=l=Pica  Style.  PS=2=Elite  Style. 
PS=3=Micron  Style.  These  are  sometimes  referred 
to  a  Pitch.  LX=Max  Printer  Line  for  the  PS  style. 
QQ-computed  Center  of  Page.  TB=established  TAB. 
The  Printer  Control  codes  (commands)  used  are  for 
EPSON  Compatable  Printers.  There  are  three 
Sub-routines.  <G0  SUB  2095>  prints  a  CENTERED 
CAPTION.  <G0SUB  2416 Changes  the  printer  to  ELITE 
DOUBLE  HEIGHT  CHARACTERS  and  prints  a  BILLBOARD  as 
seen  in  the  caption  above  this  column.  This 
routine  also  uses  the  next  one.  <G0  SUB  2420> 
SETS  a  Print  Style.  Example:  If  you  first  type 
<LET  PS=1>  then  GOSUB  2420,  then  the  Printer  is 
SET  to  PICA  STYLE.  The  subroutine  first  CANCELLS 
Double  Hi  characters. 

These  routines,  while  in  TS-2068  Basic,  can 
easily  be  cloned  for  the  Sinclair  QL  and  the  Z88. 
In  fact,  Quill  and  Pipedream  both  need  such 
automatic  printer  control  utilities. 

<G0  SUB  2416>  does  the  following  by  line 
number:  2416  sets  aside  the  page  center  var  "QQ" : 
sets  aside  the  control  var  "GG":  RESETS  Var  QQ  for 
Page  Center  for  ELITE  style:  SETS  PRINTER  to 
ELITE,  then  to  DOUBLE  HI:  Prints  the  caption  (M$) 
by  GO  SUB  2095:  RESETS  var  QQ  and  GG.  It  is  to  be 
noted  that  while  the  printer's  style  was  changed, 
the  style  variable  "PS"  has  not  been  changed. 
Therefore  as  the  program  moves  on  to  line  2420  the 
PS=  variable  still  represents  the  style  of  print 
that  was  in  effect. 

Line  2020  begins  a  dual  purpose  routine. 
First  to  reset  the  original  print  style  after  the 
2416  routine  has  been  used.  OR,  <GO  SUB  2420  will 
set  any  print  style  represented  by  "PS=  1  through 
3".  Explanation:  Line  2020  first  CANCELLS  DOUBLE 
HI.  Then  if  printing  in  the  COLUMN  PRINT  MODE,  cp 
is  greater  than  1,  so  Micron  Print  style  is  set  to 
PS=3. 


Print  and  Format  Utilities 

2095  LPRINT  TAB  qq-LEN  m$/2;m$:  LET  nn=nn+l 

2096  IF  gg=l  THEN  RETURN 

2097  GO  TO  fm 

2413  IF  IN.  127=253  THEN   GO  TO  2413 

2414  RETURN 

2416  LET  a=2413:  LET  ga=gg:  LET  gg=l:  LET  qz=qq: 
LET  qq=(qq*96/120  AND  ps=3)+(qg*96/80  AND  ps=l) 
+(qq  AND  ps=2):  GO  SUB  a:  OUT  127,27:  GO  SUB  a: 
OUT  127,120:  GO  SUB  a:  OUT  127,1:  GO  SUB  a:  OUT 
127,27:  GO  SUB  a:  OUT  127,77:  GO  SUB  a:  OUT  127, 
27:  GO  SUB  a:  OUT  127,119:  GO  SUB  a:  OUT  127,1: 
GO  SUB  2095:  LET  qq=qz:  LET  gg=ga 
2420  LET  a=2413:  GO  SUB  a:  OUT  127,27:  GO  SUB  a: 
OUT  127,119:  GO  SUB  a:  OUT  127,0:  IF  cp>0  THEN 
LET  ps=3 

2422  IF  ps=l  THEN  GO  SUB  a:  OUT  127,27:  GO  SUB 
a:  OUT  127,80 

2424  IF  ps=3  THEN  GO  SUB  a:  OUT  127,27:  GO  SUB 
a:  OUT  127,103 

2425  IF  ps=2  THEN  GO  SUB  a:  OUT  127,27:  GO  SUB 
a:  OUT  127,77 

2426  GO  SUB  a:  OUT  127,27:  GO  SUB  a:  OUT  127,120 
:  GO  SUB  a:  OUT  127,2:  IF  cp<l  THEN  LET  11=(INT 

(80*lI/lx+.5)  AND  ps=l)+(INT  (96*ll/lx+.5)  AND 
ps=2)+(INT  (120*ll/lx+.5)  AND  ps=3) 

2427  LET  lx=(80  AND  ps=l)+(96  AND  ps=2)+(120  AND 
PS=3) 

2428  IF  cp<l  THEN  LET  tb=INT  ((lx-ll)/2+.5) :  LE 
T  qq=INT  (lx/2+,5) 

2430  IF  cp>0  THEN  LET  tb=(8  AND  cp<2)+(62  AND  c 
P>1):  LET  qq=(34  AND  cp<2)+(87  AND  cp>l):  LET  11 
=50 

2434  RETURN 

2436  REM  **  For  the  QL,  the  Basic  Interpreter 
doesn't  accept  some  of  the  BOOLEAN  Logic  expres- 
ions  that  are  in  the  above  lines  and  the  lines 
will  have  to  be  broken  down  into  QL  IF  THEN 
LOGIC.  "BOOLEAN  LOGIC  FOR  QL  PROGRAMMING"  would 
make  an  interesting  Article-  Any  Volenteers? 


Lines  2422  thru  2425  SETS  a  print  style, 
PS=l=Pica,  PS=2=ELITE,  PS=3=Micron  (pitch).  Line 
12427  SETS  Letter  Quality  Mode,  then  Computes  a 
Line  Length  (LL)  that  Matches  the  length  of  line 
that  was  previously  in  use  with  the  previous  print 
style.  Then  the  Maximum  Printer  line  (LX)  is 
assigned  for  the  current  PS=print  style.  LINE 


October  1989 


9 


Update  Magazine 


Update  Magazine 


October  1989 


12428  assigns  a  new  TAB  (TB)  that  will  result  in 
the  new  style's  print  margins  being  aligned  with 
the  previously  printed  lines.  At  this  point  if 
Column  printing  is  NOT  in  effect,  the  job  is  done. 

Line  2430  works  if  Column  Printing  is  in 
effect  (CP  is  Greater  than  Zero).  First  Left  tab 
is  set  for  either  Left  column  (CP=1)  or  Right 
Column  (CP=2).  Then  Column  Center  (QQ)  is  set  for 
either  Left  or  Right  Column.  Then  the  Line  Length 
is  set  to  50. 

USAGE:  <LET  M$=HA  Caption">  <GO  SUB  2095> 
Prints  a  Centered  Caption.  <GO  SUB  2416>  Changes 
to  ELITE  DOUBLE  HI,  and  then  prints  a  Billboard 
Caption.  <LET  PS=1  thru  3>  <GO  SUB  2420>  Changes, 
the  printer  setting  to  the  Style  of  "PS=M, 
computes  MATCHING  Line  for  the  new  style  of  print. 

Line  "BU"  is  line  2413  which  checks  the 
printers  status.  If  the  printer  is  BUSY  then  <IM 
127=253>  and  the  program  continues  to  LOOP  Line 
2413  until  the  status  changes  to  READY. 


1989  SINCLAIR  COMPUTER  JEST 


This  utility 
Update  Magazine. 


is  donated  to  Public  Domain  by 

'jo**- 
L+Tf>  / 


He  are  sponsoring  the  1990  Sinclair  Fest  in 
Milwaukee.  The  Date  will  be  June  1  through  3, 
1990.  That  is  Friday  through  Sunday  and  is  the 
first  week  end  in  June.  Motels  will  charge  a  flat 
rate  of  $45  per  room,  no  matter  how  many  will 
occupy  the  room.  Rooms  will  have  two  double  beds. 
Roll  away  beds  extra  charge.  Motel  has  a  nice 
indoor  pool  and  the  food  is  excellent. 

A  banquet  is  featured  at  6:30  on  Friday 
night.  He  are  planning  to  have  a  variety  of 
displays  including  Packet  Radio.  Seminars  are 
wide  open  and  you  are  invited  to  head-up  one. 
Vendors  are  invited  to  participate.  Tables  are 
available.  Set  aside  the  first  week  end  of  June 
for  an  enjoyable  Sinclair  Fest.  The  cost  is 
right!  Contact:  Bill  Heberling  (414-527-2191). 
Or  Hrite:  SMUG  BYTES,  5052  N.  91st  St.,  Milwaukee, 
HI  53225. 


Ed  Notes :  Two  more  issues  of  Update  between 
now  and  then  will  bring  more  from  SMUG  about 'the 
Fest.  For  those  New  Englanders,  Hesterners,  and 
Southerners,  Milwaukee  is  a  nice  spot  to  vacation 
in  June.  Lotsa  unusual  attractions,  such  as  the 
Experimental  Aircraft  Asso.  Museum,  plus  others 
for  the  family.  A  good  place  to  visit,  with  down 
to  earth  prices!!  fCAflflpMu  l\c<.tpt-ti  t\T  PA*V? 


The  TI  Group  in  the  Boston  Computer  Society  is  planning  an  Orphan 
Computer  Fair  in  April /May  1980.  Although  it's  in  its  early  stages, 
we  are  very  excited.  The  TI  Group  has  had  past  shows  that  have  been 
profitable,  so  there  is  a  track  record  of  successful  organization. 

For  the  record,  we  in  the  Sinclair  Group  do  not  see  it  as  competing 
with  the  SMUG  efforts  since  it  will  largely  be  for  New  Englanders. 

However,  we  like  the  concept.  With  each  passing  year  the  number  of 
persons  interested  in  a  Sinclair-only  show,  will  necessarily  be 
fewer.  The  more  bodies  who  come  into  a  show,  the  greater  the 
potential  to  draw  vendors  with  a  range  of  stuff,  particularly  those 
in  the  generic  product,  liquidation  and  remainder  business,  who 
would  not  see  a  one-product  show  as  justifying  the  time  and  expense. 

There,  is  also  the  reality  that  the  more  people  who  come,  the  greater 
the  sense  of  camaraderie  that  can  lead  to  a  longer  life  for  support 
of  such  computers. 

1  hope  that  SMUG  will  consider  broadening  their  concept  to  include 
other  orphan  groups  from  the  Milwaukee  area. 


10 


October  5  989 


Updwle  Magazine 


Update  Magazine 


October  1989 


QL    NUMBERS    INTO  TEXT 

Peter  Hale,  P.O.  Box  8763,    Boston,  MA  02114 


Computers  should  save  time  and  effort.  This 
program  for  the  QL  does  both. 

It's  purpose  is  to  convert  a  number  (entered 
as  numerals)  into  an  equivalent  word  string. 
E.G.  input  111.11  and  the  program  returns 
ONE  HUNDRED  ELEVEN  AND  11/100. 

The  program  handles  numbers  up  to  999999.99 
and  converts  them  to  the  equivalent  words. 

Originally,  the  program  was  part  of  a  check 
writing  routine  in  ARCHIVE.    Here,  it  is 
converted  to  SuperBASIC,  while  retaining  the 
Archive  syntax  wherever  possible. 

Enter  the  listing.    Start  by  entering  the 
procedure  sav  at  line  1400.   As  you  enter 
the  listing,  occassionally  save  the  work-in- 
progress  by  typing  sav  <ENTER>  from  the 
keyboard. 

Run  the  program  by  lrun  flp2_number  <ENTER> 
or,  if  the  program  is  in  memory,  type  either 
run,  start  or  askjao,  followed  by  <ENTER>. 

Although  there  is  limited  application  beyond 
check/receipt  writing  for  this  program,  it 
is  interesting  to  show  the  differences  and 
similarities  between  SuperBASIC  and  ARCHIVE. 

When  entering  the  program  in  the  edit  mode 
of  ARCHIVE,  ignore  lines  10  and  20.  Enter 
each  procedure  (ignoring  line  numbers). 

There  are  two  other  differences.   Where  the 
program  has  a  line  with  a  REMark  in  it,  this 
is  the  ARCHIVE  syntax  to  replace  the  Super- 
BASIC line  immediately  below  it. 

The  other  difference  is  universal.  Wherever 
SuperBASIC  uses  the  ampersand  (&),  ARCHIVE 
requires  the  plus  sign  (+). 

To  run  the  ARCHIVE  version  type  run  <ENTER>, 
then  number  <EKTER>.   This  auto-starts  the 
program  by  searching  out  the  procedure 
called  start. 

The  SuperBASIC  program  version  is  'over- 
written' to  preserve  the  ARCHIVE  syntax  that 
"will  also  operate  in  SuperBASIC. 


For  example,  procedures  no_l  (line  400), 
no_2  (line  600)  and  noja  "(line  800)  could 
use  SuperBASIC 's  coercion  by  changing  all 
occurance  of  nu$  to  nu  and  removing  the 
quotes  from  the  numerals.   Also,  one  line  IF 
statements  need  not  end  with  :  END  IF  nor  is 
it  necessary  to  use  the  Keyword  LET  in 
SuperBASIC. 

The  program  points  up  a  weakness  of  coercion 
and  SuperBASIC's  handling  of  floating  point 
numbers  in  the  procedure  ask_no  at  line  100. 

In  Archive,  the  statement  after  the  REMark 
in  line  120  quickly  converts  numerals  to 
text  strings  with  an  accuracy  of  up  to 
sixteen  (16)  places. 

SuperBASIC  gets  tangled  coercing  numbers  of 
more  than  eight  (8)  significant  places  (the 
decimal  point  counts  as  a  place).  Thus, 
100000.01  would  not  be  accurate  without  the 
slicing  and  concatenation  in  line  130. 


THE  LISTING: 

10  ask_.no:  REMark  not  for  ARCHIVE  version 
20  : 

100  DEFine  PROCedure  ask_.no 

110   INPUT  "Enter  number  as  digits  ";n 

120   REMark  let  nn$=str(n,0,2) 

130  nl$=INT(n) :n2$=INT( ( (n-INT(n) )+5E-3) 

*100):nn$=nl$&".H&n2$ 
140   convert :ask_no 
160  : 

170  DEFine  PROCedure  convert 
180  REMark  let  dp=instr(nn$,".H) :  let  nn=l 
190   dp=V  INSTR  nn$:nn=l 
200   IF  dp=2:no_l:  END  IF 
210    IF  dp=3:no_2:  END  IF 
220    IF  dp=4:no_3:  END  IF 
230   IF  dp=5:no_4:  END  IF 
240    IF  dp=6:no_5:  END  IF 
250    IF  dp=7:no_6:  END  IF 
260   LET  txt$="  "&txt$&"AND  "& 
nn$(dp+l  TO  dp+2)&7l00" 
270    IF  LEN(txt$)<55 
280    REMark  let  txt$=rept("*",54- 

len(txt$))+txt$ 
290  txt$=FILL$("*",54-LEN(txt$))&txt$ 
300    END  IF 
310    PRINT  txt$ 
320  END  DEFine  convert 
330  : 


October  1989 


11 


Update  Magazine 


Update  Magazine 


October  1989 


400  DEFine  PROCedure  no_l 
410   LET  nu$=nn$(nn) :  LET  nol$="" 
420   IP  nu$="0M  AND  dp=2:  LET  nol$="ZERO  ' 


430 
440 
450 
460 
470 
480 
490 
500 
510 
520 


END  IF 
IF  nu$='T': 
IF  nu$=H2": 
IF  nu$="3": 
IF  nu$="4": 


LET  nol$="ONE  ":  END  IF 
LET  nol$=HTWO  " >  END  IF 
LET  nol$="THREE  ":  END  IF 
LET  nol$="FOUR  ":  END  IF 
IF  nu$="5":  LET  nol$="FIVE  ":  END  IF 
IF  nu$="6":  LET  nol$="SIX  ":  END  IF 
IF  nu$=H7M:  LET  nol$="SEVEN  ":  END  IF 
IF  nu$="8":  LET  nol$="EIGHT  ":  END  IF 
IF  nu$="9M:  LET  nol$="NINE  ":  END  IF 
LET  txt$=nol$ 
530  END  DEFine  no  1 
540  : 

600  DEFine  PROCedure  no_2 
610   LET  nu$=nn$(nn):  LET  no2$="H 

IF  nu$="r':no_2a:  RETurn  :  END  IF 
IF  nu$="2H:  LET  no2$="TWENTY":  END  IF 
IF  nu$="3":  LET  no2$="THIRTY":  END  IF 
IF  nu$="4":  LET  no2$="FORTY":  END  IF 
IF  nu$="5M:  LET  no2$=MFIFTYM:  END  IF 
IF  nu$="6":  LET  no2$="SIXTYH:  END  IF 
IF  nu$="7":  LET  no2$=HSEVENTY":  END  IF 
IF  nu$="8":  LET  no2$="EIGHTY":  END  IF 
IF  nu$=w9":  LET  no2$="NINETYM:  END  IF 
LET  nn=nn+l:no_l 
IF  nu$oM0M  AND  nn$(nn-l)<>"0" 
LET  no2$=no2$&"-M 
ELSE  :  LET  no2$=no2$&"  ":  END  IF 
LET  no2$=no2$&nol$:  LET  txt$=no2$ 
760  END  DEFine  no  2 
770  : 

800  DEFine  PROCedure  no_2a 
810  LET  nn=nn+l:  LET  nu$=nn$(nn) 

IF  nu$="0":LET  no2$="TEN  " : END  IF 
IF  nu$='T':LET  no2$="ELEVEN  " : END  IF 
IF  nu$="2":LET  no2$=HTWELVE  ":END  IF 
IF  nu$="3":LET  no2$="THIRTEEN  ":END  IF 
IF  nu$="4":LET  no2$="FOURTEEN  " : END  IF 
IF  au$=H5"';LET  no2$="FlFTEEN  ":ENQ  IF 
IF  nu$=V:LET  no2$="SIXTEEN  " : END  IF 
IF  nu$="7M:LET  no2$="SEVENTEEN  " : END  IF 
IF  nu$="8":LET  no2$="EIGHTEEN  " : END  IF 
IF  nu$="9":LET  no2$="NINETEEN  " : END  IF 
LET  txt$=no2$ 
930  END  DEFine  no  2a 
940  : 

1000  DEFine  PROCedure  no_3 
1010  LET  nu$=nn$(nn):  LET  no3$="M:no_l 

IF  nol$o"H:  LET  no3$=nol$& "HUNDRED  " 
ELSE  :  LET  no3$=HH:  END  IF 
LET  nn=nn+l:no_2 

LET  no3$=no3$&no2$:  LET  txt$=no3$ 


620 
630 
640 
650 
660 
670 
680 
690 
700 
710 
720 
730 
740 
750 


820 
830 
840 
850 
860 
870 
880 
890 
900 
910 
920 


1020 
1030 
1040 
1050 


1060  END  DEFine  noj 


1070  : 

1100  DEFine  PROCedure  no_4 

1110   LET  nu$=nn$(nn):no_l 

1120   LET  no4$=nol$&MTHOUSAND  " 

1130   LET  nn=nn+l:no_3 

1140   LET  no4$=no4$&no3$:  LET  txt$=no4$ 

1150  END  DEFine  no  4 

1160  : 

1200  DEFine. PROCedure  no_5 

1210  LET  nu$=nn$(nn):no_2 

1220   LET  no5$=no2$&"THOUSAND  " 

1230  LET  nn=nn+l:noJ 

1240   LET  no5$=no5$&no3$:  LET  txt$=no5$ 

1250  END  DEFine  no  5 

1260  : 

1300  DEFine  PROCedure  noj 

1310   LET  nu$=nn$(nn):no_3 

1320   LET  no6$=txt$&"THOUSAND  " 

1330   LET  nn=nn+l:no_3 

1340   LET  no6$=no6$&no3$:  LET  txt$=no6$ 

1350  END  DEFine  no  6 

1360  : 

1400  DEFine  PROCedure  sav 

1410   REMark  save  "f lp2_number" 

1420   DELETE  "f lp2_numberM: 

SAVE  Hflp2_numberH 
1430  END  DEFine  sav 
1440  : 

1450  DEFine  PROCedure  start 

1460  ask  no 

1470  END  DEFine  start 

Note:  This  article  is  prepared  on  a  24  pin 
Panasonic  KX-1124  printer  in  letter  quality 
Courier  font,  micron  (15  char/inch)  pitch. 

It  requires  only  minor  adjustments  to  Epson 
control  codes  through  the  install Jas 
program  to  access  the  vast  majority  of  the 
features  of  this  printer  under  Quill. 

SERIOUS  BUSINESS!  I've  been  in  a  quandry  for 
a  year  about  TO  or  NOT  To  buy  a  Hard  Drive  for  my 
QL.  Al  Feng's  article  on  Networking  turned  the 
trick!  I'm  gonna.  Here  is  my  rationale.  My  QL's 
are  operating  SUPER  STABLE,  and  I  do  believe  that 
I  have  more  computing  power  than  does  one  have 
with  an  IBM  AT,  except  for  the  hard  drive.  The 
Brit  Pound  conversion  is  about  1.55,  which  means 
that  a  Hard  Drive  at  355  pounds  comes  to  about 
'$550.00  (US).  Last  year  I  paid  $650.00  for  a  40 
mgbt  hard  drive  for  my  Son's  IBM,  and  then  had  to 
buy  a  $175.00  controller  for  it.  The  price  for 
the  QL  Hard  Drive  is  right!  Now  picture  this: 
Two  QL's  networking,  one  with  2  floppies  and  the 


October  1M{4 


12 


Update  Magazine 


Update  Magazine 


October  1989 


PRINTERS  and  PRINTER  CONTROL 

The  genesis  of  this  work-up  goes  back  to  my 
early  work  with  the  Sinclair  ZX-81,  a  computer 
designed  "not  to  print".  Soon  after  the  Z-81 
reached  the  "million  mark",  Cottage  industry 
developed  Machine  Code  "Printer  Drivers".  From 
then  until  today,  our  Sinclair  Computer  fans  have 
not  had  a  minimum  diet  of  "How  To  Control 
Printers".  That  is,  other  than  via  using  a 
copyrighted  software  and  following  the  manual 
instructions. 

CONCEPTS:  1.  Printer  Driver  Software:  These 
Machine  Code  utilities  provide  the  Software  LINK 
between  the  Computer,  the  Centronics  Parallel 
Interface,  and  the  Printer.  The  "prcode"  program 
usually  resides  in  RAM,  but  some  prcodes  are  put 
into  EPROM.  The  code  programs  work  marvelously  to 
send  BURSTS  of  data  from  the  computer  to  the 
printer.  Such  bursts  of  data  are  not  FORMATTED. 
Thus,  a  separate  software  is  needed  to  control  the 
data  bursts  so  that  Afaganistan,  is  printed  in  its 
entirety  on  the  same  line  of  print.  Also,  and 
this  is  the  thrust  of  this  article,  the  USER  NEEDS 
PRINTER  CONTROL.  User  control  is  needed  so  that 
there  is  a  way  to  make  the  printer  change  its 
STILE  of  PRINT  and  other  PRINTER  MODES,  via 
software  or  direct  COMMANDS. 

ADDITIONAL  CONCEPTS:  Some  Computers,  such  as 
the  Unexpanded  QL  and  the  TS-2068,  have  little 
spare  FREE  MEMORY  to  store  elaborate  ancillary 
programs  such  as  Printer  Control  utilities.  Thus 
any  such  utility  should  be  as  brief  as  is 
practical  to  do  the  jobs  needed.  What  are  the  JOB 
TASKS  that  most  users  need  for  controlling  a 
printer  "that  the  prcode  does  not  accomplish"? 
Lets  list  them:  1.  Menu  Control  for  Automatic 
printer  MODE  Changes.  2.  Line  Length  Control.  3. 
Page  Length  Control.  4.  Margins  Control.  5. 
Center  Print  of  Headers  Footers.  Each  of  these 
have  branch  needs. 

I  didn't  list  this  one  because  it  is  so 
broad.  There  are  many  different  kinds  of 
printers.  A  control  program  "for  just  one 
printer"  would  have  very  limited  application.  He 
really  need  a  "universal  printer  control  system" 
that  can  be  used  for  Dot  Matrix  printers,  Daisy 
Wheel  Printers,  and  all  makes  of- both.  Now  that 
is  a  tall  order,  isn't  it?  AND  is  is  make  even 
taller  when  one  attempts  to  develop  a  Control 
System  that  works  with  both  the  Sinclair  QL  and 
the  TS-2068.  The  task  must  be  approached  with  the 


knowledge  that  some  "user  adjustments"  will  always 
be  required  for  different  computers  and  different 
printers,  and  different  Centronics  Interfaces.  If 
the  needs  for  user  adjustments  are  well  defined, 
then  such  a  universal  program  will  be  useful  to 
many. 

PRINTER  CONSIDERATIONS 

THE  NEW  24  PIN  PRINTERS:  Recently  one  of 
Update 's  printers,  a  Star  Micronics  1000  dot 
matrix,  reached  its  365th  day  of  warranty,  and 
promptly  expired.  *  The  Print  Head  quit  printing 
half  of  the  characters,  which  made  English  look 
like  gobelexe,  a  dialect  of  the  Australian 
aborigines.  To  get  it  fixed  would  have  required 
about  $85  skins,  which  did  not  seem  to  be  cost 
effective,  what  with  the  "out  of  the  door,  out  of 
warranty"  situation  with  repairs.  So  I  opted  for 
a  new  Panasonic  KXP-1124  printer.  This  is  a  24 
pin  printer,  whereas  the  old  Star  was  a  8  pin 
printer.  Why  mention  that?  Well  I  have  read 
where  there  is  much  confusion  as  to  whether  our 
computers  (QL  and  TS-2068)  will  even  work  with  a 
24  Pin  Printer.   Lets  put  that  to  rest  imediately. 

THEY  WILL,  and  with  GUSTO!  AND  without  any 
kludge-up  at  all.  If  your  8  pin  Dot  Matrix  prints 
something  via  "LPRINT",  it  will  do  the  same,  but 
with  three  times  better  print  quality  than  with  an 

8  pin  printer.  "3  times  better"  because  the  24 
pin  printer  prints  three  times  as  many  dots  for  a 
character  printed.  DRAFT  quality  with  the  24  pin 
printer  is  better  than  NLQ  quality  with  most  8  or 

9  pin  printers.  For  proof  of  that,  this  column  is 
printed  with  the  new  24  pin  printer  (in  Draft 
Mode). 

DAISY  WHEEL  PRINTERS:  The  main  difference  in 
these  and  Dot  Matrix  is  the  Daisy  Wheel  has  a 
"print  wheel"  that  has  "whole  formed  characters". 
A  solenoid  Whacks  the  reed  that  has  the  "die  of 
the  character",  and  a  perfect  character  prints  to 
paper.  The  other  main  difference  is  that  a  Daisy 
Wheel  printer  is  SLOW,  about  17  characters  per 
second  speed.  Daisy  Wheel  printers  are  easier  to 
control  than  dot  matrix  printers.  This  is  because 
there  are  only  a  few  different  modes  of  printing, 
and  my  new  Panasonic  has  more  than  5000  different 
possible  set  ups.  Of  course,  that  many  set-ups 
are  impossible  to  program  in  an  automatic  Menu 
Controlled  program.  So  we  must  select  a  dozen  or 
so  "preferred  modes"  and  use  the  printer's  front 
panel  switches  to  control  the  unusual  modes. 


October  1989 


13 


Update  Magazine 


Update  Magazine 


Universal  Variable  Pile,  Hvarset.B6" 
Donated  to  Public  Domain  bj  Update  Magazine 

9902  CLEAR  :  LET  a=0:  LET  b=0:  LET  c=0:  LET  xx=0:  LET 
al=0:  LET  u$="M:  LET  w$="":  LET  m$=HM:  LET  sp=2Q76:: 
FOR  r=l  TO  1:  NEXT  r:  LET  pe=5898:  LET  11=64:  LET  tb 
=8:  LET  pp=0:  LET  sd=0:  LET  nn=0:  LET  ln=58:  LET  oa=l 
:  FOR  n=l  TO  1:  NEXT  n:  LET  jy=Q:  DIM  h$(l,l):  DIM  i$ 
(1,1):  LET  id=Q:  LET  a4=Q:  FOR  y=l  TO  1:  NEXT  y:  LET 
turbo=0:  LET  a3=0:  LET  red=0:  LET  ml=10Q:  DIM  v$(l,l) 
:  LET  x=0:  LET  nt=0:  LET  nz=0:  LET  zl=0:  LET  z2=0:  LE 
T  mm=0:  LET  1x=80:  LET  1=0:  LET  dl=0:  LET  d2=0:  LET  a 
lt=Q:  LET  pa=2:  LET  oo=0:  LET  ob=2:  LET  oc=3:  LET  od= 
4:  LET  oe=5:  LET  of=6:  LET  og=7:  LET  oh=8:  LET  oi=9: 
LET  oj=10:  LET  ok=ll:  LET  ol=12:  LET  om=13:  LET  on=14 

9940  DIM  o$(l,l):  LET  op=15:  LET  oq=16:  LET  or=17:  LE 
T  os=18:  LET  ot=19:  LET  ou=20:  LET  ov=21:  LET  ow=22: 
LET  ox=23:  LET  oy=24:  LET  oz=25:  LET  zo=27:  LET  po=12 
7:  LET  tel=3742:  LET  pc=0:  LET  az=0:  LET  no=0:  LET  cx 
=0:  LET  cx=0:  LET  eq=0:  LET  ep=0:  LET  ik=2554:  LET  il 
=2550:  LET  kl=100Q:  LET  k2=2Q00:  LET  k3=3000:  LET  k4= 
4000:  LET  k5=5000:  LET  k6=6000:  LET  k7=7000:  LET  k8=8 
000:  LET  k9=9000:  LET  m2=200:  LET  m3=300:  LET  m4=400: 
LET  m5=500:  LET  m6=600:  LET  m7=700:  LET  m8=80Q:  LET 
m9=9Q0:  LET  t3=30:  LET  t4=40:  LET  t5=50:  LET  t6=60:  L 
ET  t7=70:  LET  t8=80:  LET  t9=90:  LET  sq=2576:  LET  seq= 
0:  LET  alt=2070:  LET  gg=0:  LET  fm=2Q70:  LET  ed=2926: 
LET  te=3741:  LET  tel=3742:  LET  ml=2000:  LET  rp=2100: 
LET  fo=2083 

9960  LET  qa=0:  LET  sx=oo:  LET  xy=oo:  LET  ep=0:  LET  eq 
=0:  LET  cx=0:  LET  cy=0:  LET  pc=0:  LET  ax=0:  LET  no=0: 

LET  xl=0:  LET  rpr=0:  LET  pt=0:  LET  ms=0:  LET  mx=0:  L 
ET  gg=0:  LET  lb=0:  LET  z2=0:  LET  zy=0:  LET  spl=0:  LET 

qq=0:  LET  scp=0:  LET  nm=0:  LET  zm=0:  LET  mz=Q:  LET  a 
x=0:  LET  no=0:  LET  nx=0:  LET  x5=0:  LET  df=0:  LET  xl=l 
:  LET  x2=l:  LET  sr=0:  LET  sw=Q:  LET  spl=0:  LET  rpr=0: 

LET  lm=0:  LET  ms=0:  LET  in=0 

9991  POKE  23298,22:  POKE  23299,8:  LET  mt=8031:  LET  co 
m=0:  LET  bu=8080:  LET  exp=0:  LET  it=0:  LET  und=0:  LET 

scrp=Q;  LET  ih=l:  LET  pg=l:  LET  cp=Q:  LET  xa=l*.  LET 
q$=««:  LET  r$="w:  LET  s$="M:  LET  *$="":  DIM  n$(13,31) 
:  LET  n$(6)="UpDate  Magazine":  LET  n$(7)="1317  Stratf 
ord  Ave.":  LET  n$(8)="Panama  City,  FL  32404":  LET  n$( 
9)sM904  871  3556M:  LET  n$(ll)=MSincerely,M:  LET  n$(12 
)=H904  871  4513M:  LET  n$(13)=MBill  Jones":  LET  a$="": 

LET  b$="":  LET  c$=M":  LET  d$="":  LET  e$="":  LET  f$=" 
":  LET  g$=M":  LET  j$=M":  DIM  k$(l):  LET  1$="" 


October  1989 


There  are  four  programs  to  be  presented. 
Each  is  done  for  the  TS-2068,  but  each  can  easily 
be  adapted  for  the  QL,  that  is,  if  I  can 
adequately  explain  the  programming  rationale. 
Lets  start  with  the  program  "varset.B6".  This  is 
a  program  designed  to  be  MERGED  to  either  the 
TS-2068  or  the  QL.  The  program  has  HIGH  LIRE 
numbers  that  should  not  interfere  with  any 
existing  program.  All  of  the  variables  used  in 
the  other  three  programs  are  "initialized"  by 
this  "varset.B6"  program  via  <GO  TO  9902>.  ONCE 
DONE,  you  can  DELETE  the  program,  as  the  variables 
are  then  in  memory.  Use  <DELETE  9902, >  and  the 
vars  table  will  stay  in  memory  for  your  work  with 
the  other  three  programs.  This  variable  file 
forms  the  basis  for  MUCH  MEMORY  SAVINGS  in  all 
programming  that  you  will  create. 

As  a  general  rule,  if  your  Basic  program  is 
over  4K  in  program  length,  the  use  of  these 
variables  within  the  program  (instead  of  raw 
numbers)  will  equalize.  That  is  to  say,  that  the 
memory  loss  of  1751  bytes  for  the  vars  file 
storage  in  memory  will  be  recouped.  After  that, 
the  continued  use  of  the  vars  instead  of  raw 
numbers  will  multiply  in  memory  savings.  A 
typical  program  length  of  20K  will  be  reduced  by 
about  5000  bytes  via  the  use  of  the  vars  for 
numbers.  I  use  a  system  that  lends  itself  to  easy 
recollection.  Numbers  zero  through  25  are 
represented  by  the  "oo"  variables,  "zero=oo, 
oa=l,ob=2,  through  on=14.  Skip  oo  because 
oo=zero,  pick  up  with  on=16,  through  oz=25". 

One  can  count  on  one's  pinkies  at  first  until 
their  habitual  use  sinks  into  the  noggin,  and  one 
thinks  "oj  instead  of  ten".  Then  "tens"  are  "t3 
through  t9".  "t3=30,  t4=40,  etc".  Then  Hundreds 
are  represented  by  "Ml  through  H9"f  and  Thousands 
are  represented  by  "Kl  through  K9".  Thus  <GO  TO 
k2+ob>  would  be  <GO  TO  2002>.  All  other  variables 
in  the  "varset.B6"  file  are  oft  used  numbers  in 
the  Daisy. B6  Software.  These  "line  numer  and 
program  specific  vars"  may  be  changed  for  the 
needs  of  a  specific  program.  So  much  for 
"varset.B6".  Key  it  in  and  SAVE  it  to  disk.  Once 
done  you  can  always  MERGE  it,  then  <G0  TO  9002>  to 
initialize  this  variable  file  . 

Hie  "fcmat.B6fl  Program 

THE   FORMAT  MENU   GROUP,  and  the  PRINT  STYLE 


October  1989 


14 


Update  Magazine 


Update  Magazine 


October  1989 


The  Format  Menu  Group,  "fomat.B6H 

Donated  to  Public  Domain  by  Update  Magazine 

2080  RANDOMIZE  USR  ml:  LOAD  "fo5.ClHSCREEN$  :  LET  mat 
=11:  LET  xo=lx:  LET  lo=ll:  LET  rs=id:  LET  cp=oo:  LET 
lh=oo 

2081  PRINT  AT  oi,VAL  M24M;Mid=";id;H  ";AT  oe,os;("ft" 
AND  sd<ob)+(M  M  AND  sd>oa);AT  offos;(T  AND  sd>oa)+ 

("  H  AND  sd<ob);AT  op,ob;("Pica  M  AND  ps<ob)+(MEliteM 
AND  ps=ob)+("Cond  "  AND  ps>ob);AT  ot,ob;lx;AT  op,oq; 
qq;AT  op,VAL  M28M;ln;AT  ot,oi;ll;AT  ot,oq;mat;AT  or,V 
AL  "28";nn;AT  os,VAL  M28M;pg;AT  at, VAL  "28M;tb:  GO  SU 
B  sq:  GO  SUB  il:  GO  TO  {z=oh)*VAL  "2093"+(z>oh)*VAL  M 
2081"+(z<oa)*VAL  "2081"+(z>oo  AND  z<oh)*VAL  M2082M 

2082  IF  x=og  THEN  LET  lx=(VAL  H126M  AND  pr>oa)+(VAL 

M120M  AND  pr<ob):  LET  11=(VAL  M50M  AND  pr>oa)+(VAL  M4 

8M  AND  pr<ob):  CLS  :  PRINT  AT  oj,ob;"Start  Col  1  or  2 
?m.  IKpuT  „key  1  Qr  2„;cp.  Ip  cp=Qa  THEK  LET  qq=jrv& 

L  "34"  AND  pr>oa)+(VAL  "34  AND  pr<ob"):  LET  tb=oj 

2083  IF  z=og  AND  cp=ob  THEN  LET  qq=(VAL  "90"  AND  pr= 
ob)+(VAL  "86"  AND  pr=oa):  LET  tb=(VAL  "64"  AND  pr=ob) 
+(VAL  M62M  AND  pr=oa) 

2084  IF  x=og  THEN  LET  ps=oc:  IF  pr=oa  THEN  LET  com= 
oa:  GO  SUB  VAL  "498":  LET  a=VAL  "2413":  GO  SUB  a:  OUT 

po,VAL  M27M:  GO  SUB  a:  OUT  po,VAL  "27M:  GO  SUB  a:  00 
T  po,VAL  "120":  GO  SUB  a:  OUT  po,oai  GO  SUB  a:  OUT  po 
,VAL  H27M:  GO  SUB  a:  OUT  po,VAL  M103M 

2085  LET  sd=(z  AND  z<oc)+(sd  AND  z>ob):  IF  z=od  THEN 
LET  tb=(tb-oe  AND  ll<lx-oi)+(tb  AND  ll>lx-oj):  LET  1 

l=(ll+oj  AND  ll<lx-oi)+(H  AND  ll>lx-oj):  LET  id=id-o 
j:  BEEP  oa/od,ol:  PRINT  AT  ot,oi;ll;AT  ot,oq;mat;AT  o 
t,VAL  "28";tb;"  H:  GO  TO  VAL  "2081" 

2086  IF  x=oe  THEN  LET  tb=(tb+oe  AND  ll>ou)+(tb  AND  1 
KVAL  "21"):  LET  ll=(ll-oj  AND  ll>ou)+(ll  AND  1KVAL 
"21"):  LET  id=id+oj:  BEEP  oa/od,ol:  PRINT  AT  ot,oi;ll 
;AT  ot,oq;mat;AT  ot,VAL  "28";tb;"  ":  GO  TO  VAL  "2081" 

2087  GO  TO  (Koc)*VAL  "2Q8r+,(x=oc)*VAL  "2Q93"+(x>oc) 
*VAL  "2088" 

2088  BEEP  oa/od,os:  LET  lh=(oa  AND  z=oh)+(oo  AND  z<>o 
h):  IF  cp<oa  AND  pr=oa  THEN  LET  lx=(VAL  "120"  AND  ps 
>ob)+(VAL  "96"  AND  ps=ob)+(VAL  "80"  AND  ps<ob):  REM  D 
ot  Matrix 

2089  IF  cp<oa  AND  pr=VAL  "2"  THEN  LET  lx=(VAL  "124" 
AND  ps>VAL  "3")+(VAL  "96"  AND  ps=VAL  "3")+(VAL  "80"  A 
ND  ps<VAL  "3"):  LET  qq=INT  (lx/ob):  REM  Daisy 

2090  CLS  :  PRINT  AT  oj,ob;"INPUT  Printer  Line  Spacin 
gM""<l>  l/8""=76  lines;"""<2>  ll/64""=56  LinesM,,M< 
3>  3/16""=50  Lines"M"<4>  l/4""=37  Lines":  INPUT  x:  L 
ET  ln=INT  (VAL  ".6"+{VAL  "9.5"/VAL  ".125"  AND  x<ob)+( 
VAL  "9.57VAL  ".172"  AND  x=ob)+(VAL  "9.5"/VAL  ".187" 
AND  x=oc)+(VAL  "9.5"/VAL  ".25"  AND  x>oc)):  CLS  :  PRIN 
T  AT  oj,ob;"Set  Printer  for  Line  Spacing""TAB  ob;"Th 


MENU  GROUP:  These  two  programs  work  hand  in  glove 
to  provide  a  miriad  of  PRINTER  CONTROL  and 
FORMATTING  needs.  He  will  first  discuss  the 
FORMAT  MENU  GROUP,  which  is  designed  to  provide 
Automatic  Format  assistance.  The  Menu  Itself  is 
reproduced  below.  Incidentally,  this  menu  is 
produced  "right  within  the  text",  using  the 
Daisy. B6  software  for  the  TS-2068. 


Select  until  Finished 

<1>  Sngle  Spc 

<2>  Dbl  Spc 

<3>  Print  Style  Menu 

<4>  Block  Indent  Off 

<5>  Block  Indent  ON 
<6>  To  Fun  Menu 
<7>  Column  Print 
<8>  Let  Head  Stnry 

2083 

Pg  Cent=      Pg  Lgth= 

Max     Line    Match  Line= 
Line    Lgth    Line  Page= 
Tab  = 


For  cross  reference  purposes,  you  can  refer 
to  the  above  Menu,  its  numbered  selections,  and 
the  LLIST  of  ""fomat.B6"".  The  menu  is  a 
"rotary",  in  that  all  selections  "1  through  5" 
return  the  menu  after  the  selection  task  is  done. 
These  selections  cause  a  graphics  block  to  be 
posted  to  show  the  new  status.  The  current  Format 
Status  is  displayed  with  their  vars 
identification.  This  makes  a  pretty  busy  screen 
display,  but  one  that  keeps  you  oriented  as  to  the 
format  status. 

When  referring  to  the  LLIST,  there  is  one  odd 
character  that  is  wrong  in  many  places.  The  "|" 
in  the  listing  is  actually  a  graphics  block,  which 
is  posted  at  various  places  on  screen  to  designate 
current  status.  When  keying  in  use  the  graphics 
block  for  this  character.  The  menu  provides  many 
electives  for  Formatting.  Some  electives  follow 
via  prompts  after  the  selection  is  made  to  return 
to  the  FUNCTION  MENU.  Basically,  the  menu 
electives  cause  calculations  for  using  Format  Line 
Length,  TAB,  and  Center  of  Page,  to  format  CENTER 
PRINTED  LINES  on  a  page.  We  start  with  the 
premise  that  the  printer  itself  is  DUMB,  and  is 
set  to  its  start  up  initialization  parameters.  NO 


October  1989 


15 


Update  Magazine 


Update  Magazine 


October  1989 


MARGINS,  no  Porportional  Print,  and  the  printer  is 
set  for  the  usual  60  lines  per  page  (most 
initialize  that  May). 

Two  special  set-ups  are  provided.  <LETT£R 
HEAD  Stationary>  selection  sets  variable  "lh"  to 
be  used  bj  a  word  processor.  The  Daisy  program 
that  uses  this  group  of  menus  uses  var  HlhN  to 
roll  up  12  lines  before  printing  the  Business 
Block  of  a  letter.  This  lets  one  use  pre-printed 
letterhead  stationary.  Then  if  a  second  page 
prints,  it  begins  at  the  regular  place  on  pageX" 
from  the  top  of  form.  < COLUMN  PRINT>  selection 
results  in  a  prompt  "Start  at  Col  1  or  Col  2?", 
then  "Start  at  Line  I?".  This  allows  one  to  start 
column  printing  anywhere  with  either  the  left 
column  or  the  right  column. 

When  in  Column  Print  Mode,  the  line  length 
and  left  margin  are  set  for  fixed  values.  (50 
chrs  per  line  for  Dot  Matrix,  or  52  for  Daisy 
Wheel  printers).  You  can  change  this  in  line 
number  2082.  The  TAB  "tb"  and  Center  of  page  "qg" 
may  also  be  changed  for  your  Condensed  print  line 
length.  One  should  have  CONDENSED  PRINT  set  up 
either  manually  or  via  the  Style  Menu  to  use  the 
Column  Print  mode.  The  PAGE  END  utility  "pe.B6" 
is  used  by  the  Dasiy.B6  program  for  Switching 
columns  in  mid  print  stream.  The  text  is  printed 
beginning  at  the  column  selected,  and  continues 
printing  alternate  columns  until  all  data  has  been 
printed.  This  works  better  with  Cut  Sheets,  as 
you  can  re-insert  the  page  at  each  page  end  to  let 
the  next  column  print  on  the  same  page. 

This  Panasonic  dot  matrix  printer  allows 
Paper  Parking,  and  Cut  Sheets  to  be  fed  into  the 
printer  from  the  front.  This  way,  I  can  print 
alternate  columns  on  the  same  page.  Also,  to  be 
experimented  with  is  a  capability  to  "reverse 
direction  line  feed".  Perhaps  I  can  develop  a 
little  routine  for  tan  fold  forms  to  "back  up  to 
the  top  of  form"  and  continue  column  print  on  the 
same  fan  fold  page?  In  discussing  these 
functions,  the  Daisy  software  is  used  as  an 
example  of  how  the  miriad  of  Formatting  functions 
can  be  used  by  a  software,  using  the  array  of 
FORMATTING  VARIABLES  that  are  established  at  this 
format  menu.  In  a  later  issue  of  Update  we  will 
give  the  "LINE  FORMATTER-PRINTER"  which  makes  use 
of  the  printing  variables  that  this  "fomat.B6" 
program  establishes.  For  now,  you  can  see  the 
results  in  these  printed  columns. 

Hhen  FUNCTION  MEHU>  is  the  selection,  a 


en  Enter  Lines  per  page?""TAB  ob;"Current  page  lgth= 
";ln:  INPUT  In:  CLS  :  INPUT  "Enter  Pagel";pg:  INPUT  " 
Enter  Line  Count  start";nn:  IF  cp>oo  THEN  GO  TO  VAL 
"2092" 

2091  CLS  :  PRINT  AT  oj,oo;"Line  length3"; 11' '"Match  L 
ine=";matM:  INPUT  "New  Line  Length?";  11:  LET  qq=INT 
(lx/ob+oa/ob):  LET  tb=INT  ((lx-ll)/ob+oa/ob):  PRINT  " 
Tab=";tb:  INPUT  "New  Tab?";tb 


The  Style  Menu  Group,  "stymn.B6" 

Donated  to  Public  Domain  by  Update  Magazine 

8001  LET  it=oo:  LET  com=oo:  LET  exp=oo:  LET  und=oo:  L 
ET  scrp=oo 

8002  RANDOMIZE  USR  ml:  LOAD  "ps.Cl"SCREEN$  :  LET  c=(o 
f  AND  ps<ob)+(og  AND  ps=ob)+(oh  AND  ps>ob):  PRINT  AT 
of,ob;H  ";AT  og,ob;"  ";AT  oh,ob;H  H;AT  c,ob;T;AT  os 
,og;lx;"  ";AT  os,op;tb;"  ";AT  ot,og;qq;"  ";AT  ot,op;l 
1;"  ";AT  oj,ob;("  "  AND  com=oo)+("ft"  AND  com=oa);AT  o 
l,ob;("  "  AND  scrp=oo)+("£"  AND  scrp=oa);AT  om,ob;(" 
"  AND  exp=oo)+("|"  AND  exp=oa);AT  on,ob;("  "  AND  it=o 
o)+(T  AND  it=oa);AT  op,ob;("  H  AND  und=oo)+("ft"  AND 

und=oa):  LET  px=ps:  LET  xo=lx:  LET  px=ps:  LET  lo=ll 

8003  GO  SUB  sq:  GO  SUB  il:  IF  Koa  OR  i>oi  THEN  GO  T 
O  VAL  "8003" 

8004  IF  x=oi  THEN  GO  TO  VAL  "8114" 

8005  IF  pr>oa  THEN  LET  lx=(84  AND  ps<ob)+(VAL  "98"  A 
ND  ps=ob)+(VAL  "126"  AND  ps>ob):  LET  qq=INT  (lx/ob+oa 
/ob) 

8006  IF  pr=oa  THEN  LET  lx=(VAL  "80"  AND  ps<ob)+(VAL 
"96"  AND  ps=ob)+(VAL  "120"  AND  ps>ob):  LET  qq=INT  (lx 
/ob+oa/ob) 

8010  IF  pr=oa  AND  i=od  THEN  LET  com=oa:  GO  TO  VAL  "8 
002" 

8012  IF  pr=oa  AND  i=oe  THEN'  LET  scrp=oa:  GO  TO  VAL  " 
8002" 

8014  IF  pr=oa  AND  x=o£  THEN  LET  exp-oa:  GO  TO  VAL  "8 

002" 

8016  IF  px=oa  AND  i=og  THEN  LET  it=oa:  GO  TO  VAL  M*u 
02" 

8018  IF  pr=oa  AND  i=oh  THEN  LET  und=oa:  GO  TO  VAL  "8 
002" 

8020  IF  Kod  THEN  LET  ps=l 

8021  IF  pr=ob  THEN  LET  lx=(VAL  "84"  AND  ps=oa)+(VAL 
"98"  AND  ps=ob)+(VAL  "124"  AND  ps=oc):  LET  qq=INT  (lx 
/ob+oa/ob):  GO  SUB  VAL  "8026":  GO  TO  VAL  "8002" 

8024  CLS  :  PRINT  AT  oj,oe;"One  Moment  Please-"' 'TAB  o 
c;MPrinter  is  setting.  .  .":  LET  lx=(VAL  "80"  AND  ps= 
oa)+(VAL  "96"  AND  ps=ob)+(VAL  "120"  AND  ps=oc):  LET  q 
q=INT  (lx/ob+oa/ob):  GO  SUB  mt:  GO  SUB  VAL  "8050" 
8026  LET  ma=INT  (oa/ob+lx*lo/xo):  GO  SUB  VAL  "8028": 
BEEP  oa/ob,ov:  GO  TO  VAL  "8002" 
8028  CLS  :  PRINT  AT  oj,ob;"Key  in  Line  Length" "TAB  o 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


b;lx;"=Max  ";ma;"=Hatch  Margins":  INPUT  "Input  Line 
Length  LET  tb=IKT  ((li-ll)/ob+oa/ob) :  CLS  :  RE 
TURN 

8030  REM  **  The  Dot  Matrix  Printer  C 
ontrol  ** 

8031  IF  prooa  THEN  RETURN 

8034  GO  SUB  bu:  OUT  po,VAL  M18M:  GO  SUB  bu:  OUT  po,VA 

L  "27":  GO  SUB  bu:  OUT  po,VAL  "119":  GO  SUB  bu:  OUT  p 

o,oo:  GO  SUB  bu:  OUT  po,VAL  K27M:  GO  SUB  bu:  OUT  po,V 

AL  H53H:  GO  SUB  bu:  OUT  po,VAL  "27":  GO  SUB  bu:  OUT  p 

o,VAL  "45":  GO  SUB  bu:  OUT  po,oo 

8036  GO  SUB  bu:  OUT  po,VAL  H27N:  GO  SUB  bu:  OUT  po,VA 

L  "120":  GO  SUB  bu:  OUT  po,oa:  GO  SUB  bu:  OUT  po,VAL 

"27":  GO  SUB  bu:  OUT  po,VAL  MiQ7w:  GO  SUB  bu:  OUT  po, 

(oo  AND  ps<oc)+(ob  AND  ps>ob) 

8038  GO  SUB  bu:  OUT  po,VAL  "27":  GO  SUB  bu:  IF  ps=oa 

THEN   OUT  po,t8 

8040  IF  ps=ob  THEN  OUT  po,VAL  "77" 
8042  IF  ps=oc  THEN  OUT  po,VAL  "103" 
8044  RETURN 

8050  IF  com=oa  THEN  LET  lx=(VAL  M137"  AND  ps<ob)+(VA 
L  "160"  AND  ps=obMVAL  M120M  AND  ps=oc):  LET  qq=INT 
(lx/ob+oa/ob):  GO  SUB  bu:  OUT  po,VAL  M27M:  GO  SUB  bu: 
OUT  potVAL  "15" 

8052  IF  exp=oa  THEN  LPRINT  :  LET  nn=nn+oa:  GO  SUB  bu 
:  OUT  po(YAL  "27":  GO  SUB  bu:  OUT  po,VAL  "119":  GO  SU 
B  bu:  OUT  po,oa 

8054  IF  it=oa  THEN  GO  SUB  bu:  OUT  po,VAL  M27M:  OUT  p 
o,VAL  H52M 

8056  IF  und-oa  THEN  GO  SUB  bu:  OUT  po,VAL  H27M:  GO  S 

UB  bu:  OUT  po,VAL  "45":  GO  SUB  bu:  OUT  po,oa 

8058  IF  scrp=oa  THEN  GO  SUB  bu:  OUT  po,VAL  "27M:  GO 

SUB  bu:  OUT  po,VAL  H120H:  GO  SUB  bu:  OUT  po,oa:  GO  SU 

B  bu:  OUT  po,VAL  "27'':  GO  SUB  bu:  OUT  po,VAL  "1Q7M:  G 

0  SUB  bu:  OUT  po,od: 

8060  RETURN 

8080  IF  IN  127=253  THEN  GO  TO  bu 
8082  RETURN 


Mpe.B6",  the  column  switching  Page  End  Routine 
Donated  to  Public  Domain  by  Update  Magazine 

5900  IF  pr=oo  THEN  LPRINT  " ' "  ;TAB  qq;pg"  " ' ' ' " 
' :  LET  nn=oa:  LET  pg=pg+oa:  RETURN 

5901  IF  nn<ln+ob  THEN  LPRINT  :  LET  nn=nn+oa:  IF  nn 
<ln+ob  THEN  GO  TO  VAL  H5901M 

5902  IF  cp>oo  THEN  GO  TO  VAL  "5906" 

5903  LPRINT  TAB  qq;pg:  LET  nn=oo:  LET  pg=pg+oa:  OUT 
po,ol:  IF  pr=oa  THEN  GO  TO  VAL  M5913M 

5904  GO  SUB  VAL  "5912":  GO  TO  VAL  "5913" 

5906  IF  cp=ob  THEN  LPRINT  TAB  lx/objpg:  LET  pg=pg+ 
oa 

5908  OUT  pa,ol:  LET  nn=oa:  IF  pr>oa  THEN  GO  SUB  VA 
L  "5912" 


series  of  prompts  appear  to  allow  "Exceptional" 
Formats.  These  allow  one  to  input  different  TAB 
and  LINE  LENGTH  to  achieve  OFF-SET  printing.  The 
printing  variables  are  normally  set  for  text 
printing  to  be  centered  on  page,  or  in  pre-set 
columns.  These  prompts  offer  the  choices  of  other 
formats.  Also,  a  pair  of  prompts  allow  for 
condensing  or  expanding  the  increments  of  spacing 
between  lines,  to  produce  such  printing  as 
subscript  or  superscript,  or  Daisy  Wheel 
characters  that  have  reduced  or  expanded  height. 
For  example,  one  use  that  I  make  of  these  prompts 
is  to  use  a  print  wheel  having  reduced  height 
charcters  that  produce  76  lines  of  characters  on  a 
page,  instead  of  a  normal  page  of  56  lines. 

The  "fomat.B6"  program  allows  fgr  either 
Daisy  Wheel  or  Dot  Matrix  printers  that  have 
different  "maximum  columns  per  line".  This 
differentiation  is  detected  by  variable  "pr=l  for 
Dot  Matrix"  or  "pr=2  for  Daisy  Wheel".  This  also 
is  a  nicety  of  the  Daisy. B6  software.  This  Format 
program  is  coordinated  with  the  next  program 
"stymn.B6"  which  provides  for  both  Daisy  Wheel  and 
Dot  Matrix  Printer  control. 

The  Format  program  works  on  "an  existing 
print  style"  to  allow  a  complete  range  of  formats 
to  be  set  up.  But  in  one  instance  it  does 
actually  change  a  print  style.  That  is  when 
"Column  Print"  is  elected.  Then  the  printer  if 
commanded  to  change  to  "Micron  pitch",  which  for 
some  printers  is  called  "Condensed".  This 
produces  120  Character  line  (maximum.  Column 
print  is  automatically  set  for  50  character  lines 
for  this  printer. 

USING  MERGE/DELETE 

THE  MERGE  CONCEPT:  All  of  these  programs  are 
designed  to  be  MERGED  to  any  operating  Program, 
and  once  used  to  be  DELETED.  A  typical  program 
line  to  MERGE  the  "fomat.B6M  program  is  given  in 
TS-2068  LKDOS  Syntax:  <2079  RANDOMIZE  USR  100: 
MERGE  "fomat.B6">.  Then  anywhere  within  the  host 
program,  <GO  TO  2079>  will  MERGE  the  fomat.B6 
program  and  it  will  operate.  A  typical  DELETE 
line  (after  the  fomat.B6  program  has  been  used) 
would  be:  <2Q93  DELETE  2080,2091:  GO  TO  fm>. 
These  two  lines  are  exactly  the  ones  used  in  the 
Daisy  software  to  Merge  in  the  Format  Menu  and 
when  finished  with  it  to  delete  it.  Note  the  menu 
routing  in  line  2081  in  which  if  <8  Format  Menu  is 
elected>  the  program  is  DELETED  by  line  2083. 
Since  you  only  need  such  menus  to  Set  Up 
Parameters  Ocasionally,   it  shouldn't  be  stuck  in 


17 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


memory  to  sacrifice  data  capacity. 

The  PAGE  END  PROGRAM 

The  PAGE  END  ROUTINE,  "pe.B6":  This  utility 
is  given  only  because  it  relates  to  the  "Column 
Print  Mode"  as  set  up  by  the  Format  Menu.  This 
program  ALSO  is  designed  to  work  with  either  Daisy 
Wheel  or  Dot  Matrix  Printers.  If  using  a  Daisy 
Wheel,  a  prompt  is  given  to  "Service  Printer", 
which  means,  "Feed  another  Sheet,  or  Re-insert  the 
Same  Sheet".  This  allows  the  alternate  Column  to 
be  printed  on  the  same  page.  For  Dot  Matrix 
printers  (pr=l),  the  pause  is  not  given  between 
pages.  The  variable  "cp"  value  of  1  or  2  is  used 
to  switch  to  the  alternate  column,  then  re-set  the 
TAB  "tb"  for  printing  the  next  column.  Again,  the 
differences  between  print  size  between  a  Dot 
Matrix  and  a  Daisy  Wheel  printer  is  accounted  for 
in  the  calculations.  Ordinary  printing  with  "page 
width"  '  columns  bypasses  the  "column  switcher" 
because  "cp=0". 

Bffi  STYLE  MEHU  GROUP 


Select  Print  Style 

<1>  Pica  -80-  Com=137 
<2>  Elite  -96-  Com=160 
<3>  Micron-120-  same 

<4>  Com  137/160  ]  * 
] 

<5>  Script  3  Set 

<6>  Expand  Height  ]  First 

<7>  Italics  ] 

<8>  Underline  ] 
<9>  Format  Menu 


LX=80 
QQ=4Q 


TB=15 
LL=50 


8000 


The  program  "stymn.B6"  is  the  PRINT  STYLE 
MENU  and  the  PRINTER  CONTROL  PROGRAM.  This 
program  is  also  designed  to  be  MERGED  as  needed, 
and  when  it  is  used,  to  be  DELETED  from  memory. 
The  program  line  to  MERGE  "stymn.B6"  is  given  in 
TS-2068  LKDOS  syntax  to  be  emulated  by  other  DOS 
Syntax.  It  is:  <8000  RANDOMIZE  USR  100:  MERGE 
"stymn.B6">.  Then  the  DELETE  LINE  is:  <8114 
DELETE  8001,8082:  GO  TO  fm>.  "fm"  is  line  12070 
of  the  Daisy  software  (is  Function  Menu). 


5909  LET  cp=(oa  AND  cp=ob)+(ob  AND  cp=oa):  IF  cp=oa 
THEN   LET  qq=(VAL  "34"  AND  pr=ob)+(VAL  "34"  AND  pr 

=oa):  LET  tb=oh 

5910  IF  cp=ob  THEN  LET  qq=(VAL  "92"  AND  pr=ob)+(VA 
L  "86"  AND  pr=oa):  LET  tb=(VAL  "66"  AND  pr=ob)+(VAL 

"62"  AND  pr=oa) 

5911  GO  TO  VAL  "5913" 

5912  BEEP  oa,ov:  CLS  :  PRINT  AT  oj,ob;"Feed  New  She 
et,  then  ENTER":  PAUSE  oo:  LET  nn=oo:  CLS  :  RETURN 


The  MERGE  LINE:    5899  PRINT  |4:  MERGE  "pe.B6" 
The  DELETE  LINE:    5914  DELETE  5900,5912:  RETURN 


"stymn.B6"  first  defines  the  "font  variables" 
in  line  18001.  They  are:  "it=l  for  Italics", 
com=l  for  Compressed  print,  exp=l  for  EXPAND 
Hight,  und=l  for  Underline  ON,  scrp=l  for  Script 
style  ON.  These  are  control  variables  that  are 
set  by  the  menu  electives  4  through  8.  They  are 
not  "Print  Sixes".  The  first  three  1-3  electives 
are  "Print  Size  or  Style".  The  menu  is  a  "rotary" 
in  that  the  selections  4  through  8  are  used  first 
to  elect  the  fonts.  None  of  these  affect  the 
actual  width  of  the  characters, except  "4 
Compress",  which  has  different  results  depending 
upon  the  basic  print  style  in  use.  Once  the  fonts 
have  been  elected,  and  up  to  four  may  be  combined, 
the  last  selection  is  the  Print  Style  (1  through 
3). 

The  selections  1-3  selects  the  Print  Style. 
Line  #8020  is  reached  only  by  selecting  one  or  the 
three  basic  Print  Styles  (1-3).  This  line  assigns 
the  Print  Style  variable  "ps=l  through  3".  Then 
lines  8021  through  8028  are  executed.  Twin 
routines  are  for  either  Dot  Matrix  or  Daisy  Wheel 
printers.  These  are  differentiated  by  the 
variable  "pr=l  for  Dot  Matrix,  or  pr=2  for  Daisy 
Wheel".  Other  operating  vars  are  "ll=Line  Length, 
qq=page  center,  tb=TAB" .  We  enter  the  program  at 
line  8001  with  these  printing  vars  having  been  in 
use  or  set  by  the  software  initialization.  Then 
at  the  last  part  of  line  18002,  these  printing 
vars  are  "set  aside  to  be  used  for  calculations" 
when  the  style  is  changed  at  menu. 

These  vars  values  are  set  aside  (in  line 
18002)  by  asigning  their  "past  values"  to  "px=ps, 
xo=lx,  and  lo=ll.  Then  px  and  ps=  the  previous 
print  style  1-3,  xo  and  lx=  the  previous  Max 
Printer  line  for  the  past  print  style  in  use.  "lo 


OctoDer  1989 


Upaate  Magazine 


Update  Magazine 


October  1989 


and  11"=  the  past  Line  Length  in  use.  The 
calculations  beginning  at  line  8021  computes  a 
"MATCHING  Set  of  Parameters"  so  that  you  can  elect 
a  MATCHING  Line  length  for  a  new  print  style 
selected  at  menu.  The  Matching  Line  length  is 
presented  on  screen  with  a  prompt  "Input  Line 
Length".  Then  computations  are  done  to  FORMAT 
THAT  Line  Length  to  he  centered  on  page.  A  new 
TAB  "tb"  and  Page  Center  "qq"  is  calculated  and 
assigned.  Now  we  have  Line  Length  "11",  page 
center  "qq",  and  TAB  "tb"  assigned  for  the  newly 
selected  print  style. 

At  this  time,  if  Daisy  Wheel  printer  is  in 
use  (pr=2),  the  Style  Menu  is  re-called,  where  an 
escape  is  provided  back  to  the  FORMAT  Menu.  The 
Daisy  Wheel  printer  requires  no  further 
commanding,  because  it  has  a  fixed  print  wheel. 
Why  then  do  we  even  use  the  Style  menu  for  a  Daisy 
Wheel?  Well,  it  is  quick  and  easy  to  change  print 
wheels,  and  this  program  will  match  up  the 
printing  with  a  new  print  wheel's  style  of  print. 

m  ma  mm  vim 

The  DOT  MATRIX  PRINTER  CONTROL  Section  begins 
at  line  18034.  After  all  of  the  calculations  has 
been  done  and  the  Format  for  the  New  Style  of 
print  has  been  set  up,  an  obscure  command  in  line 
18024  is  "GOSUB  mt",  followed  by  "GOSUB  8050". 
"Line  mt"  is  8031.  We  will  now  SET  THE  PRINTER  to 
the  newly  selected  style  and  fonts.  This  section 
deserves  the  most  explanation  because  it  is  where 
most  users  will  have  to  work  on  to  Match  the 
Printer  Control  Commands  to  their  specific 
printer.  It  really  is  quite  SIMPLE,  and  YOU  CAN 
DO  IT! 

THE  PRINTER  CONTROL  GROUP  FOR  A  PANASONIC 
KX-P1124  24  pin  Dot  Matrix  Printer:  We  begin  at 
LINE  18031  which  rejects  anything  BUT  a  Dot  Matrix 
Printer.  Then  the  Dot  Matrix  Control  section 
begins  at  line  18034.  The  very  first  task  to 
perform  is  to  RESET  the  Printer  to  its  TURN  ON 
STATUS-  That  is  EXCEPT  for  the '  TOP  OF  FORM 
setting.  We  do  this  by  installing  the  proper 
"CANCEL  COMMANDS"  for  every  special  Font  and  Style 
that  we  use.  This  cancels  the  printer  back  to  its 
"Initialisation  Status  upon  Turn  ON",  —  EXCEPT 
for  the  TOP  OF  FORM  setting.  The  total  number  of 
these  CANCEL  commands  depend  upon  the  total  number 
of  the  Special  Fonts  and  Print  Styles  that  the 


program  is  to  use.  If  you  dont  USE  a  Printer 
Function,  then  it  isn't  necessary  to  CANCEL  that 
function.  The  three  Print  Styles  (for  this 
printer)  does  not  need  to  be  cancelled. 

QL  Users  take  note:  The  protocol  for  sending 
control  codes  to  a  printer  is  different.  The 
PRINCIPLE  though  is  the  same.  The  printer  must  be 
hit  with  a  CONTROL  CODE  to  respond  and  change  an 
internal  setting.  We  do  that  with  the  TS-2068 
(Aerco  and  Oliger  Interface)  by  <0UT  127,code>. 
Some  other  TS-2068  interfaces  use  <LPRINT  CHR$ 
code>.  A  printer,  such  as  the  KXP-1124  may  be  "an 
EPSON  Compatable"  printer,  but  that  does  not  mean 
that  its  required  Command  Codes  are  the  same  as  an 
Epson  Printer.  Most  printers  require  different 
Control  Codes  to  do  similiar  or  identical  internal 
changes.  There  are  three  methods  for  sending 
Control  Codes  to  the  Printer.  QL  users  must  use 
PRINT  CHR$  number  to  the  Serial  Port.  TS-2068 
users  of  Aerco  and  Oliger  Printer  code  sends  these 
commands  via  <OUT  127, number >. 

Other  TS-2068  users  of  TASMAN  or  other  prcode 
may  need  to  use  LPRINT  CHR$  (number).  If  you  use 
TASMAN  or  another  interface  than  Aerco  or  Oliger, 
then  consult  your  Interface  manual  for  the  proper 
way  to  send  command  characters  to  the  printer.  We 
will  use  the  method  for  the  TS-2068  Aerco  or 
Oliger  interfaces.  The  next  is  where  your  PRINTER 
MANUAL  is  the  KEY.  You  must  decide  WHICH  of  the 
special  fonts  and  styles  that  you  want  to  have 
done  automatically  with  the  menu  control,  then  go 
about  using  the  printer  manual  to  dig  out  both  the 
"SET  and  CANCEL"  comands.  You  can  use  the 
rationale  given  herein  and  corrolate  with  your 
printer  manual  to  develop  the  programming  changes 
in'  these  line  numbers  "that  will  command  your 
printer"  to  accomplish  the  style  changes.  But  the 
following  NEEDS  are  Common  to  all. 

COtfflNDIMG  THE  PRINTER 

The  first  part  of  this  Printer  Control 
Section  is  to  Set  the  Printer  Back  to  its  Turn  On 
STATE,  without  resetting  the  TOP  of  FORM.  Then 
printing  can  resume  with  a  new  style  of  print  and 
the  software  can  retain  PAGE  CONTROL.  You  can  see 
by  the  Menu  Illustration  the  styles  and  fonts  that 
"I  selected"  for  my  Printer.  Now  the  first  task 
to  do  is  to  CANCEL  all  of  these  settings.  At  Line 
8034  we  start  by  <GO  SUB  BU>  which  throws  you  for 
a  loop,   eh?    Well,  "bu  is  line  18080",  and  lets 


October  1989 


19 


Update  Magazine 


Update  Magazine 


October  1989 


look  at  that. 

The  purpose  of  line  18080  is  to  check  to  see 
if  the  PRINTER  IS  BUSY.  The  printer  goes  through 
a  routine  of  "turning  itself  off  or  onM  to  do 
internal  changes.  ONE  Control  Command  sent  from 
the  keyboard  is  acted  upon  by  the  printer  faster 
than  one  can  type  and  send  the  next  command.  But, 
in  software  lines,  the  computer  is  sending  control 
codes  faster  than  the  printer  can  react  to. 
Therefore  a  LOOP  is  needed  to  check  the  Printer's 
status  before  sending  the  NEXT  control  command. 
The  TS-2068  uses  the  IK  command  through  "Port 
127".  Most  TS-2068's  will  return  M253M  if  the 
printer  is  BUSY  or  OFF  LINE. 

To  check  yours,  first  turn  ON  your  Printer, 
then  INITIALIZE  your  PRINTER  CODE.  Then  leave 
your  printer  ON,  but  switch  it  OFF  LINE.  Then 
type:  <PRINT  IN  127  ENTER>.  "IN"  is  the  token 
below  the  I  Key.  If  you  get  some  other  number 
than  253,  then  use  that  number  instead  of  253  in 
line  8080.  Now  we  can  go  back  to  line  18034  to 
continue  to  CANCEL  all  printer  functions  that  we 
will  use  in  the  "stymn.B6"  program.  The 
programming  is  used  <OUT  PO,18>.  The  variable 
"po=127",  so  that  means  <OUT  127, 18>.  This  is  to 
CANCEL  the  Compressed  Mode  of  print.  Between  each 
OUT  command,  <G0  SUB  BU>  is  used  to  loop  line  8080 
until  the  printer  is  READY.  So,  we  wont  discuss 
the  <G0  SUB  BU>  any  more.  Next  in  line  18034  the 
grouped  command  <27,119,0>  is  sent  to  the  printer 
in  similiar  fashion  with  <OUT  PO>.  This  Cancels 
the  "Double  High  character"  Mode. 

Next  <27,53>  is  sent  to  CANCEL  ITALICS  Mode. 
Then  <27,45,Q>  is  sent  to  CANCEL  UNDERLINE  MODE. 
Now  this  is  all  of  the  special  settings  that  is 
used  in  this  program  that  are  not  "self  cancelling 
when  an  alternate  selection  is  made".  If  you  use 
more  in  your  programming  then  you  must  include  *- 
CANCEL  COMMANDS  in  this  line  of .programming.  AND- 
your  printer  may  require  all  or  some  more  of  the 
print  style  settings  to  be  CANCELLED  before 
another  can  be  set.  An  Okidata  Printer,  for 
example,  requires  the  existing  print  style  to  be 
CANCELLED  before  another  style  can  be  set. 


Line  18036  begins  the  "PRINTER  SET  Commands". 
The  first  group,  <27,120,Q>  sets  LETTER  QUALITY 
Mode.  Then  <27,107,num>  sets  one  of  two  font 
styles  (Bold  if  in  Pica  or  Elite)  or  COURIER  if  in 
Micron  Pitch.  Line  8038-8044  sets  the  print  style 
selected  at  menu.  Then  the  programming  RETURNS  to 
LINE  8024  where  another  GOSUB  is  to  Line  8050.  At 


line  8050-8056  the  special  fonts  are  set, 
compressed,  double  height,  Italics,  or  Script. 
Then  RETURN  goes  to  line  18026  where  the  Matching 
Line  length  is  calculated,  and  tab  and  page  center 
is  set.  The  Style  Menu  is  again  presented  where 
it  is  appropriate  to  select  a  return  to  the  Format 
Menu,  as  the  work  is  done.  On  the  way  back  to  the 
Style  Menu,  line  18114  DELETES  programming  from 
memory.  The  Format  Menu  and  the  Style  Menu  work 
together  as  a  suite  for  both  Format  and  Printer 
Control .  _BJ- 

SUMMARY 

The  use  of  MERGE  and  DELETE  together  can 
broaden  your  programming  horizons.  By  the  use  of 
these  powerful  functions,  you  can  bring  utilities 
aboard  a  running  program,  use  them  and  then 
discard  them.  This  lets  your  software  have  the 
most  data  capacity.  Printer  Control  programming 
is  needed  only  once  or  twice  while  running  a 
program.  Why  clutter  up  memory  by  keeping 
un-needed  programs  on  board?  Pardon  me  for 
showing  off  with  my  new  printer!  This  entire 
article  was  printed  non-stop  with  this  printer  and 
the  Daisy. B6  software.  I  hope  that  this 
discission  of  Printers,  their  control,  and 
Formatting  helps.  If  you  get  anything  from  this  I 
hope  that  it  is  "Dont  be  afraid  of  a  new  printer" 
and  "You  can  make  it  work".  JM- 


Left  Handed  Ways  of  Working  a  PrinterN^ 

This  small  group  of  cognizibles  are  to  given  to 
provolk  thought.  I  Just  got  a  new  Panasonic 
KXP-1124,  24  pin  dot  matrix  printer.  The  first  job 
was  to  modify  my  TS-2068  software  for  the  new 
printer.  That  done,  I  tried  the  printer  with  the 
QL.  It  worked  right  out  of  the  box  with  the  Quill 
Config  set-up.  But  there  was  no  way  of  Setting  the 
Printer's  modes  with  the  Quill  Software.  Next,  I 
did  some  printing  and  became  confused  about  how  to 
set  print  pitches  from  the  front  panel.  My  set-up 
uses  a  Centronics  "A/B"  switch  to  switch  between 
the  QL  and  the  TS-2068  to  the  printer.  The  bright 
idea  came;  "why  not  use  my  TS-2068  Daisy  software 
to  set-up  special  print  pitches  and  Letter  Quality 
mode,  and  then  throw  the  the  A/B  switch  over  to 
the  QL  for  printing?" 

-So,  here  goes.  Daisy  booted  in  and  the  Style  Menu 
was  used  to  set  Micron  120  Style,  which  gives  120 
character  lines  (17  Pitch).  The  A/B  switch  was 
moved  to  the  QL  position,  and  this  column  is  the 


October  1989 


2,0 


Update  Magazine 


Update  Magazine 


October  1989 


A  HALF   DOZEN  OR  MORE  TOG  TOOLS  BY  EARL  DUNN I NGTON 


100  REM  TOS  TOOLS  #1-5 

102  REM  REQUIRES  OS-64  CART,  CENTRONICS 

INTERFACE  &  PRINTER 

104  CLEAR  63423:  LET  A=Q:  LET  B=Q:  LET 
C=0:  LET  U$=" 

9B0Q  REM  TOOL  #1-PRINTER  INITIALIZATION 
ROUTINE 

9801  GO  SUB  9820:  PRINT  IOj'TURN  OFF  PRI 
NTER""5ET  PRINTER  SWITCHES" IF  NECESSA 
RY"STHEN  <ENTER>S:  PAUSE  0:  CLS 
9804  PRINT  #0!' INPUT  TYPE  OF  INTERFACE" 
"<1>  AERCO  OR  0LI6ER",<2>  TASMAN  B""<3 
>  TASMAN  C"'<4>  A  &  J":  PAUSE  0:  LET  ZZ 
=VAL  INKEYI :  IF  ZZ<1  OR  ZZ>4  THEN  CLS  : 
GO  TO  9801 

9806  POKE  65523,(167  AND  ZZ=1)+(135  AND 
ZZ=2)+(122  AND  ZZ=3)+(185  AND  ZZ=4) 

9807  CLS  :  INPUT  'LINE  WIDTH?" 'THEN  <EN 
TER>  "5LW 

9808  INPUT  "LEFT  MARGIN  TAB?" "THEN  <ENT 
ER>  '{TB:  IF  LW+TB>80  OR  LW+TB<1  THEN  P 
RINT  »QJ"L1NE  WIDTH  +  LEFT  MARGIN  TAB  MU 
ST  BE  LESS  THAN  81  WITH  PI CA" " <ENTER>  T 
0  CONTINUE':  PAUSE  0:  GO  TO  9807 

9809  POKE  65525, LW+TB:  GO  SUB  9821:  RAND 
OMIZE  USR  15623:  REM  The  OS-64  does  not 
have  a  single  poke  for  setting  left  raarg 
in.  Must  know  the  printer  code  if  any 

9810  GO  SUB  9820:  INPUT  '<1>  COMPUTER  LI 
NE  FEED?""<2>  NO  LINE  FEED"* THEN  <ENTE 
R>  '}LF:  IF  LF<1  OR  LF>2  THEN  GO  TO  981 
0 

9811  POKE  65510,(13  AND  LF=i)+(Q  AND  LF= 
2) 

9812  INPUT  '<i>  COMPUTER  CARRIAGE  RETURN 
?"'<2>  NO  CARRIAGE  RETURN" "THEN  <ENTER 
>  *  iCR:  IF  CR<1  OR  CR>2  THEN  GO  TO  9812 

9813  POKE  65511,(10  AND  CR=l)+(0  AND  CR= 
2)  i 

9814  PRINT  UOi'TURN  ON  THE  PRINTER,  THEN 
<ENTER>":  PAUSE  0:  GO  SUB  9821:  LPRINT 

:  CLS 

9815  FOR  N=l  TO  5:  IF  TB=Q  THEN  GO  TO  9 
818 

9816  DIM  M$(TB):  LPRINT  M$; 

9818  FOR  M=l  TO  LW:  LPRINT  'X",:  NEXT  M: 
NEXT  N:  LPRINT  :  REM  Test  print  lines  f 

or  printer  whose  left  margin  code  is  not 
known 

9819  STOP 

9820  CLS  :  OUT  255,0:  OUT  244,0:  BORDER 
Q:  PAPER  0:  INK  5:  CLS  :  RETURN  :  REM  Pu 
t  OS-64  to  sleep 

9821  as  :  OUT  255,62:  OUT  244,3:  INK  7: 
CLS  :  RETURN  :  REM  wake  up  OS-64 


October  1989 


2,1 


This  program  was  converted  from  Bill  Jones  "LKDOS  TOOLS  BY 
THE  HALF  DOZEN*  published  in  the  July  issue.  Whereever  possible 
I  have  used  the  same  range  of  line  numbers. 

There  are  many  differences  between  LKDOS  and  TOS.  Rather 
than  using  RANDOMIZE  USR  100,  TOS  uses  an  asterisk  after  the 
BASIC  command  to  denote  that  it  is  a  disk  command.  TOS  has  a 
Serial  Printer  driver  and  does  not  have  a  Centronics  Parallel 
print  driver.  This  program  is  designed  for  use  with  the  OS-64 
cartridge,  a  Centronics  Parallel  printer  and  a  80  column 
monitor. 

With  the  OS-64  in  the  dock,  when  the  2068  is  powered  up, the 
screen  colors  are  set  up  with  a  64  character  display.  The 
default  printer  interface  is  either  an  AERCO  or  Oliger.  The  two 
problems  with  the  OS-64,  is  that  one  should  have  a  80  column 
monitor  and  that  there  is  no  single  POKE  for  setting  the  left 
margin  of  the  printer.  One  must  know  the  manufacturers  code  for 
setting  the  left  margin  or  program  around  it.  In  order  to  make 
this  program  universal  as  far  as  printers  go,  I  have  chosen  the 
second  option. 

The  first  two  lines  in  the  program  are  REM  statements.  Line 
104  sets  RAMTOP  as  the  OS-64  VI. 71  does  not  do  this  automatical- 
ly. This  prevents  unwanted  crashes  while  in  the  BASIC  program. 
Aswith  LKDOS  Tools,  variables  are  initialized  so  they  can  be 
found  faster  by  the  program. 

TOOL  II.  PRINTER  INITIALIZATION.  TOS  does  not  require 
initialization  like  LKDOS.  Merely  turning  on  the  drives  and  in- 
serting a  formatted  or  program  disk  accomplishes  this.  The  OS-64 
,  however,  must  be  initialized  for  type  of  interface,  number  of 
characters  per  line,  if  the  computer  must  generate  a  carriage 
return,  and  if  the  computer  must  generate  a  line  feed.  This  is 
accomplished  in  lines  9801-  to  9814. 

The  next  tool  begins  at  9815  ending  at  9819.  Itis  merely  a 
five' line  proof  test  of  the  initialization  of  the  OS+64  and  the 
printer.  To  overcome  the  lack  of  a  single  poke  to  set  the  left 
'  margin,  the  string  variable  M$  is  dimensioned  using  the  variable 
TB.  When  a  string  is  dimensioned  it  contains  only  spaces.  M$  is 
printed  at  the  front  of  each  line  to  provide  the  left  margin. 

The  next  tool  is  the  two  really  neat  subroutines,  devised 
by  Bill  Jones, that  allow  one  to  switch  from,  a  64  character  dis- 
play to  32  and  vice  versa.  They  are  contained  in  lines  9820  and 
9821.  When  in  the  32  character  mode,  you  cannot  use  LOAD,  SAVE, 
LPRINT,  or  RANDOMIZE  a  location  in  the  OS-64  without  crashing 
the  computer. 

TOOL  12.  The  CAT  print  tool  starts  at  line  9822.  As  the  old 
saying  goes,  there  is  more  than  one  way  of  skinning  a  cat.  In 
order  to  overcome  the  margin  setting  problem,  a  different  method 
is  used  from  the  one  used  by  Bill  in  his  LKDOS  CAT  Print. 

This  version  picks  up  the  characters  from  the  screen  using 

Update  Magazine 


Update  Magazine 


October  1989 


9B22  REM  TOOL  H2-CAT  PRINT-Print  a  Disk 
Catalog 

9823  PRINT  #05 "ARE  THE  DRIVES  ON  AND  IS* 
'"THERE  A  DISK  IN  "A"' DRIVE? ""TURN  OFF 

PRINTER' "<ENTER>  WHEN  READY" J  PAUSE  Q: 
CLS  :  REM  TOS  Initialization 

9824  POKE  65525,80:  RANDOMIZE  USR  15623: 
PRINT  #0;"TURN  ON  PRINTER  THEN  <ENTER>" 

:  PAUSE  Q:  CLS  :  REM  Set  LPRINT  width  to 
80 

9826  PRINT  #0;" INSERT  DISK  TO  BE  CATALOG 
ED" "IN  DRIVE  "A"'  THEN  <ENTER>":  PAUSE 

0  :  as  :  GO  SUB  9856:  GO  TO  *":*:  CAT 
*:  GO  SUB  9860:  GO  TO  t"A"d 
9830  GO  SUB  9856:  CLS  :  CAT  *:  GO  SUB  98 
60:  INPUT  "IS  THE  DISK  TREE  STRUCTURED" 
■<1>  YES""<2>  NO  ""THEN  <ENTER>  ";T:  IF 

T<1  OR  T>2  THEN   GO  TO  9830:  REM  Does  t 
he  catalog  show  subdirectories? 
9832  IF  T=l  THEN  GO  TO  9840 
9834  INPUT  "<1>  CATALOG  ANOTHER  DISK?"" 
<2>  QUIT?" "THEN  <ENTER>";S:  IF  S<1  OR  S 
>2  THEN  GO  TO  9834 
9836  IF  S=l  THEN   60  TO  9826 
9838  GO  TO  9864 

9840  INPUT  "<1>  LPRINT  ANOTHER  CATALOG?" 
"<2>  QUIT" "THEN  <ENTER>";S:  IF  S<1  OR 
S>2  THEN  GO  TO  9840 
9B42  IF  S=2  THEN  GO  TO  9864 
9844  GO  SUB  9856:  INPUT  ' INPUT  SUBDIRECT 
ORY  PATHNAME  ""THEN  <ENTER>  "?P*:  CAT  *P 
$:  GO  SUB  9860:  GO  TO  9840 
9856  INPUT  "LPRINT" "<1>  LEFT  SIDE""<2> 
RIGHT  SIDE" 'THEN  <ENTER>,jS:  CLS  :  IF 
S<1  OR  S>2  THEN  GO  TO  9856 
9858  RETURN 

9860  DIM  M*(5):  IF  S=2  THEN  DIM  M*(43): 
REM  Sets  margin 

9862  DIM  C$(32):  FOR  N=Q  TO  21:  FOR  M=0 
TO  31:  LET  C$(M+1)=SCREEN$  (N,M):  NEXT  M  ' 
:  LPRINT  M$iC$:  IF  C$(l  TO  5)*"Max  1*  TH 
EN  RETURN  s  REM  Picks  up  catalog  from* 
creen  and  prints  it 

9863  NEXT  N:  RETURN 

9864  STOP 

9868  REM  TOOL  H3-SENDING  STRING  DATA  TO 
DISK 

9869  REM  Create  the  U$  Data  first  '  Use 
CAPS  SHIFT+SYMBOL  SHIFT  to  QUIT  1  '  Use 
ENTER  for  starting  new  line  " 

9870  POKE  23730,191:  POKE  23731,247:  LET 
A=0:  LET  B=0:  LET  C=Q:  CLS  :  INPUT  "TUR 

N  DRIVES  ON,  INSERT  DATA  DISK"  "ENTER  A 
FILE  NBR  <1  TO  99999>"|ZZ:  GO  SUB  9970: 
LET  U$=":  CLS  :  PRINT  AT  21,60',LEN  U$;A 
T  A^*,'.1;:  REM  TOS  allows  8  character  n 
arse  +  period  and  3  character  file  type  e 
xtension  £2 


SCREEN$.  In  addition  Tree  Structured  or  nested  Subdirectories 
are  allowed  in  TOS.  Not  so  in  LKDOS.  Unfortunately  Tree  Struct- 
ured directories  are  stressed  in  the  TOS  manual,  rather  than 
just  formatting  a  disk,  SAVEing,  and  LOADing  a  program.  This 
makes  the  use  of  disk  drives  appear  very  coiplicated  to  the 
novice.  Actually  using  disk  drive  "A"  is  no  more  complicated 
than  using  a  tape  recorder  to  save  and  load  programs.  The  drives 
in  TOS  are  daisy  chained  to  the  "A"  drive.  That  is  a  program 
disk  must  be  in  the  "A"  .drive  for  the  other  drives  to  work.  The 
directory  in  another  drive  becomes  a  subdirectory  of  the  disk  in 
the  "A"  drive.  Printing  a  catalog  from  any  other  drive  would 
give  an  erroneous  result,  listing  a  directory  that  is  not  on  the 
disk.  For  this  reason  I  did  not  allow  the  option  of  a  change  in 
drives. 

TOOL  #3-SENDING  STRING  DATA  TO  DISK.  This  program  follows 
the  LKDOS  version  fairly  closely.  The  text  entry  display  is 
changed  to  provide  a  64  character  display.  Line  9902  inserts  an 
ENTER  character  into  US  as  an  end  of  record  marker.  TOS  allows 
65535  records  to  a  data  file.  TOS  uses  a  disk  drive  buffer  that 
allows  only  256  characters  to  be  sent  to  the  disk  at  one  time. 
Lines  9903  to  9904  utilize  string  slicing  and  a  loop  to  send  the 
string  data  to  the  disk.  Line  9940  contains  the  206B  replacement 
for  the  TS  1000/1500  SCROLL  command  (LET  t«USR  2361).  When  the 
text  input  fills  the  screen  to  the  end  of  line  20,  the  screen 
scrolls  upone  line,  leaving  the  character  counter  undisturbed. 
Line  9971  concatenates  (chains  the  parts)  of  the  file  name-into 
N$  and  opens  the  file  as  a  sequential  streem  file  (no  fixed 
record  length)  in  the  output  to  disk  mode.  TOS  allows  an  eight 
character  name  plus  an  extension  consisting  of  a  period  and  a 
three  character  data  type.  The  use  of  the  extension  with  BASIC 
program  names  is  optional. 

TOOL  M-LPRINT  OR  VIEW  A  DISK  FILE.  In  the  LKDOS  version 
Tools  3  and  4  are  intertwined.  As  I  wished  to  make  a  comparison 
of  the  two  systems  easy,  I  left  them  that  way  in  the  TOS  ver- 
sion. I  found  it  convenient,  while  programing,  to  be  able  to 
view  or  LPRINT  any  data  file.  Also  to  see  the  Catalog  while 
choosing  a  file.  I  added  these  features  in  line  9920.  Once  again 
as  the  TOS  buffer  accepts  only  256  characters  at  one  time  and 
due  to  the  OS-64  laft  margin  problem,  the  program  differs  from 
the  LKDOS  version.  TOS  allows  the  use  of  16  channels.  Four  fast 
(11-14)  and  12  slow  (#5-#16).  The  fast  channels  are  more  conve- 
nient for  reading  back  (Input)  a  stream  sequential  file  and  so 
I  used  Channel  II.  As  the  BASIC  system  does  not  recognize  the 
TOS  generated  error  reports,  ON  ERROR  GOTO  is  not  used.  To 
determine  when  the  the  End  of  File  is  reached,  lines  9930  and 
9934  illustrate  the  method  used  for  TOS. 

TOOL  15.  It  is  merely  a  subroutine  for  quick  printer  format 
changes  and  is  contained  in  line  9960.  Once  again  it  differs 
from  the  LKDOS  version  because  of  that  left  margin  problem  of  th 
e  OS-64  and  the  Smith  Corona  Fastex  80  dot  matrix  printer. 

This  article  was  typed  into  data  files  using  Tool  #3  and 
Lprinted  using  Tool  14.  One  should  remember  that  the  major  part 
of  programing  is  the  development  of  the  logic  which  was  done  by 
Bill  Jones  in  his  LKDOS  version,  Many  thanks  B?P, 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


9872  POKE  23611,220 

9874  IF  PEEK  2361U221  THEN   GO  TO  9974 
9876  LET  C=PEEK  23560:  POKE  23611,220 
9878  IF  C=12  THEN  GO  TO  9890:  REM  delet 
e  char 

9880  IF  C=13   THEN  GO  SUB  9940:  GO  SUB 
9902:  GO  TO  9872:  REM  ENTER  key 
9882  IF  C=14  THEN  GO  SUB  9902:  GO  TO  99 
06:  REM  CS+SS  keys 

9884  IF  C<32  OR  C>122  THEN  GO  TO  9872 
9BB5  PRINT  AT  A,B;CHR$  Cj:  LET  B=B+1:  IF 
B=64  THEN  GO  SUB  9940 
9886  PRINT  AT  A^i".";:  LET  U$=U$+CHR$  C 
:  PRINT  AT  21, 60; LEN  U$ 
9888  GO  TO  9872 

9890  IF  LEN  U*=0  THEN  GO  TO  9872:  REM  e 
rror  trap 

9891  LET  U$=U$(  TO  LEN  U$-l):  PRINT  AT  2 
1,60?"      ' ;AT  21.60JLEN  U*;AT  A,B,"  ": 
LET  B=B-l:  IF  B=-l  THEN  LET  B=63:  LET  A 
=A-l:  IF  A=-l  THEN  LET  A=0 

9892  PRINT  AT  A,B;"_':  GO  TO  9872 

9902  LET  U$=U$+CHR$  13:  REM  End  of  recor 
d  narker 

9903  FOR  N=l  TO  LEN  U$  STEP  256:  IF  LEN 
U$<N+256  THEN  PRINT  *#5;U$(N  TO  LEN  U$) 
:  GO  TO  9905:  REM  TOS  Drive  buffer  accep 
ts  only  up  to  256  characters  at  one  time 

9904  PRINT  *J»5|UI(N  TO  N+255):  NEXT  N 

9905  LET  U$=":  PRINT  AT  21,60,"  ':  R 
ETURN 

9906  CLS  :  INPUT  '<1>  CREATE  MORE  TEXT" 
•<2>  QUIT'JXX:  IF  XX=1  THEN  GO  SUB  9940 
:  GO  TO  9872 

9908  CLOSE  M5:  STOP 

9918  REM  TOOL  #4.  LPRINT  OR  VIEW  A  DISK 

FILE 

9920  CLS  :  CAT  *:  INPUT  "ENTER  THE  FILE 
NBR  <1  TO  99999)  ";ZZ:  INPUT  *<1>  VIEW  F. 
ILE  <2>  LPRINT  FILE  '{XX:  LET  U$=":  IF 
XX=1  THEN  GO  TO  9928 
9924  as  :  PRINT  #Q;"TURN  PRINTER  ON,,  TH 
EN  <ENTER>":  PAUSE  0:  GO  SUB  9960:  REM 
printer  initialization 

9928  as  :  LET  U*=":  GO  SUB  9980:  REM  0 
pen  disk  file  for  input  to  screen  or  pri 
nter 

9929  IF  XX=2  THEN  GO  TO  9933:  REM  send 
data  to  printer  instead  of  screen 

9930  POKE  23729,255:  INPUT  «#l;U$:  IF  PE 
EK  2372BO0  THEN  GO  TO  9946:  REM  Peek  a 
nd  Poke  are  error  trap  as  ON  ERROR  does 
not  recognize  TOS  system  errors 

9931  PRINT  U$?:  GO  TO  9930 


23 


9933  IF  LM>0  THEN  LPRINT  M$; 

9934  FOR  N=l  TO  LW:  POKE  23729,255:  INPU 
T  *#l;U*:  IF  PEEK  23728O0  THEN  LPRINT 

:  GO  TO  9946 

9935  LPRINT  U$;:  IF  U*=CHR$  13  THEN  GO 
TO  9933 

9936  NEXT  N:  GO  TO  9933 

9940  LET  A=A+U  LET  B=0:  IF  A>20  THEN  P 
RINT  AT  21,60| "      ':  LET  t=USR  2361:  LE 
T  A=20:  PRINT  AT  A,Bi"_":  RETURN 
9942  PRINT  AT  A, B ;"_";:  RETURN 
9946  CLOSE  Ml:  PRINT  #0; "REACHED  END  OF 
FILE,  PRESS  <ENTER>":  PAUSE  0 
9950  STOP 
9952  GO  TO  9920 

9956  REM  TOOL  #5.  GOSUB  ROUTINE  FOR  QUIC 
K  FORMAT  CHANGES 

9960  CLS  :  INPUT  'INPUT  TAB  " ;LM:  INPUT 
"LINE  WIDTH  ";LW:  POKE  65525, LM+LW:  RAND 
OMIZE  USR  15623:  IF  LM>0  THEN  DIM  M*(LM 

) 

9962  LPRINT  :  RETURN 

9970  REM  Assign  file  name  (N$)  and  open 
TOS  file  as  a  Stream  File 

9971  LET  N$="DTA"+STR*  ZZ+\DAT":  DIM  *N 
$:  OPEN  M5!N$;0:  RETURN 

9980  REM  Assign  file  name  Hi  and  open  th 
at  TOS  file  for  (I)nput  of  (1)  character 

at  a  time,  to  screen  or  printer  using  c 
hannel  one  (#1) 

9981  LET  N$="DTA"+STR*  ZZ+".DAT":  OPEN  # 
*UN$5l;l:  RETURN 

Speaking  of  Printers  and  their  manipulation:  My 
next  project  is  to  use  a  64K  Printer  Buffer  and  put 
it  IK  LIKE  with  an  A/B  switch.  Then  I  should  be 
able  to  feed  data  to  the  buffer  from  either 
computer.  Try  this  idea:  Create  two  documents, 
one  in  the  QL  and  another  in  the  TS-2068.  Send  the 
QL  doc  to  the  Printer  buffer.  Then  send  the 
TS-2068  doc  to  the  printer  buffer.  The  two  docs 
stack  up  in  the  buffer  and  should  print  as  one 
longer  document. 

Now  that  may  be  like  be  like  riding  two  bicycles  at 
the  same  time,  eh?  Well,  what  about  this-  We  who 
have  two  computers  often  have  documents  created 
with  Quill  or  our  TS-2068  software.  The  doc  files 
are  in  two  floppies  and  are  not  transferable 
between  the  two  computers.  Wouldn't  it  be  nice  to 
"append  a  QL  Quill  file"  with  a  TS-2068  file  in 
disk?  Could  save  a  lot  of  re- typing  or  paste  up. 


(Durned  if  it  didn't  work!) 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


GRAPH  0 f    a  POLYNOMIAL 


Polynomials  are  power  equa- 
tions of  the   type  most  often 
written  in  the   form  of  


axtb  +  cxtd  +  extf  + 


+9 


0 


where  a,   c,  e,  and   f  are  usual- 
ly small  whole,   positive  or  neg- 
ative numbers.,   and   b.   d.    f.  etc 
are  interger  exponents  arranged 
in  descending  order  of  power. 

Most  often  some  one  value,  or 
several  values,  of  x  satisfies 
this   relationship.     Uhich  is  to 
say   that  such  value  of  X.  when 
substituted  into   the  polynomial 
makes   its  overall  value  equal 
to   the  zero  on   the   right  hand 
side  of  the  equal  mark.  These 
values  of  X  are   known  as  roots 
of   the  equation,   or  simply 
roots,  and  they   can   be  rational 
or  irrational  numbers.  Irra- 
tional numbers,   you  mau  recall, 
are   those  which   cannot   be  ex- 
pressed precisely.     Some  well- 
known  ex amp les  are  ...  . 

PI   =  3.14-15927  

e    =  2.7132313  


If  equated  to  Y  instead  of  O, 
equations  of  this   type  can  be 
Plotted  on  coordinated  X-  and 
Y-axes  paper,   but   the  method  is 
usually  tedious   for  any  equa- 
tion over  the  second  power,  one 
where  the   first  exponent,  b.  is 
greater  than  two.  One  of  the 
purposes  of  plotting  such  an 
equation  is  to  determine  the 
points  where  the  curve  crosses, 
or  touches,   the  X-axis.     Such  1 
points,  where  the  value  of  X 
makes  Y  =  0,   are  roots  of  the 
equation.  • 

There  may  be  as  many  real 
roots  to  a  polynomial,  as  repre- 
sented by  the  power  of  the 
first  term  in  X.     Thus  an  equa- 
tion of  the  second  power  can 
have  two  real  roots,   but  it  mau 
also  have  none,     fin  equation  of 
the  third  power  may  have  three 
real  roots  or  one.     it  will  not 
have   less,     fin  equation  of  the 
fourth  power  may  have   four,  two, 
or  no  real  roots.     fill  of  this 
depends  upon  the  value  of  the 
last  term  of  the  equation.  Its 
value  can  raise  or   lower  the 
entire  curve  with  respect  to 
the  coordinate  axes  ..providing 
the  other  terms  remain  unchang-  \ 
ed.  \ 

filgebra  offers  several  meth-  i 
ods  of  solving  these  equations, 
fl  few  can  be   factored,  and  the 
like,   but  many  of  them  can  be 
solved   (roughly)   only  by  plot- 
ting and  tedious  trial  and  er- 
ror  calculations.  Here  is  where 
the  Timex  shines.   It  can  crunch 
numbers  and  speed  them  thru  num- 
erous and  repetitious  calcula- 
tions. Ue  will  start  by  having 
the   computer  plot   the  signifi-      ? L 
cant  part  of  the  curve   for  us.  (~ 


Program  G-ll  was  devised  to 
plot  the  curve  of  anu  power 
equation.     Normally   the  TS2063 
plots  using  pixels  as  though 
the   lower   left  corner  of  the 
screen  is  the  origin,  the 
Y-axis   the    left  edge,   and  the 
X-axis   the   bottom  edge.  Thus 
the  normal  Timex  screen  is  the 
first  quadrant.     Hence  we  must 
first   center  the  axes.     In  our 
case  we  arbitrarily  moved  the 
X-axis  up   by  36  pixels  and  the 
Y-axis  to  the  right  by  130  pix- 
els.    The  values  mentioned  are 
incorporated  into   lines  20  and 
14-0  o  f  the  program  G-ll. 

Next  there  is  a  matter  of 
scale.     Power  equations   can  de- 
velop very    large  positive  or 
negative  values  of  Y   for  rela- 
tively small  values  of  X.  For 
this  reason  vertical  and  hori- 
zontal scale    factors  are  re- 
quired.    These  are  entered  into 
the  program  in   lines  100  and 
113.   as  V  and  H.     The  corres- 
ponding scale  markings  on  the 
graph  appear  in   tines  70  and  30. 
The  relationship  between  factor 
and  scale  marking  is  


Factor 


.2 
.  4. 
.3 
1.0 
2.0 
4-.0 
3.0 


Y  Scale  Mark 


200 
100 
50 
4-0 
20 
10 


X  Scale  Mark 


5.0 
10.0 
20.0 


20 
10 


For  starters,   use  the  combina- 
tion of   factor  and  scale  mark, 
starting  with  the  top -most  pair. 
If  the  resulting  curve  is  too 
Pinched  or   compressed,  select  a 
combination   further  down  the 
table.     Line  135  prevents  those 
annoying  out -of -range  error  re- 
ports . 

Note  that   the  program  lines 
subject  to   change  with  each  new 
equation  have  been  emphasized 
by  having  their  command  words 
in  inverse   lettering.     Do  not 
enter  a  new  line  by  eradicating 
the  old  one.     Bring  the  old  one 
down  and  change  it,   leaving  the 
inverse   lettering  intact. 

Figure  1  shows  the  basic  pro- 
gram, G-ll,   built  around  the 
equati  on ..... 

Y   =  15Xt3   +   16Xt2   +  3X 

Notice  that  its  curve  shows 
three  real  roots.  If  the  equa- 
tion had  an  additional  constant 
term  of  say  +1,  the  whole  curve 
would  move  up  with  respect  to 
the  axes  and  it  would  have  only 
one  real  root. 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


Program  G-llA,  Figure  2, 
shows   the  graph  of  a  different 
equa ti  on  


Y   =  2Xt3  +   HXt2  -31X 


130 


This  one  has  three   real  roots 
which  happen  to  be  x  =  -5,  -4-. 5, 
and  +4.     They  don't  usually 
come  out  in  such  nice  little, 
rational  numbers.     The  first 
two  roots  become  apparent  when 
the  area   from  X  =  -6  to  X  =  -4 
is  expanded  by  using  a  vertical 
factor  of  U  =  t.     See  Figure  4, 
for  a  blow-up  of  this  area,  so 
treated.     Figure  3  makes  the 
curve   look  tangent  to  the  axis. 
Its  scale  is  too  small. 

G-llB,  Figure  3,  shows  the 
same  basic  program  with  a 
fourth  power  equation...... 

Y  =   6Xt4-   +   5Xt3   -5X1-2   -   5X  -1 

The  graph  of  this   curve  shows 
that  it  has   four  real   roots.  If 
the   last  term  is  changed  from 
-1  to  +3,   all  of  the   four  real 
roots  disappear.     Make  this  sub- 
stitution and  observe  the  re- 
sulting curve. 

Here  are  a   few  more  polynom- 
ials of  this  variety  to  play 
around  with  

Y  =  Xt2  -  X   -  5 

Y  =  Xt4-  -   13Xf2   +  35 

Y  =  Xt3  -  4Xt2  -  2X   +  7 

Y  =  Xt3  -  4-Xt2  -  2X  -  3 

Save  this  paper   for  future 
reference.  Programs  to  evaluate 
these  roots,  with  a  high  degree 
of  precision,  will  be  the  sub- 
ject of  a   future  tutorial. 


Uarren  Fricke 


5  REM    **    "G-ll",    7-18-39,  UF 
10  REM   **   GRAPH   Of   a  POUER 

EQUATION 
20  PLOT  0,86:    DRflU  0,-86:  DRAU 
255,0:    DRflU  0,36:    DRflU  -255,0: 
DRflU  0,39:    DRflU  255.0:    DRflU  0,-3 
9:    PLOT   130.0:    DRflU  0,175 

4-0  FOR  n=26  TO  146  STEP  20:  PL 
OT  129, n:    PLOT  131, n:    NEXT  n 

50  FOR  n=30  TO  230  STEP  20:  PL 
OT  n,37:    PLOT  n , 85 :    NEXT  n 
60  PRINT  AT  1,1; "GRAPH  Of.. 
Y " ; AT  12,30; "X " 
"   -    -•"    —  16, 


U-20 
H=20 

x=-l  TO   1   STEP  .01 

_.        ,  y =16*x*x*x  +  15*x  *x  +3*x 

135  IF  ABS  (y*U) >85  THEN  GO  TO 
150 

14-0  PLOT  X*H+130,y*U+S6 
150   NEXT  X 

16Xt3 


200]  

6Xt2  +3X" 


3,1;  "Y 


+  1 


GRAPH  of..  Y 
Y   =  16X1-3   +  16X- 

-5 

.2  +3X 

;+2 

+5 

/  w 

X 

-2 

FIGURE  1 


Musings 

Now  you  know  ole  BJ  has  a  penchant  to  ramble, 
eh?  Hell  there  is  some  scattered  space  to  fill, 
so  this  will  be  continued  all  over  the  magazine. 
I'll  try  to  make  the  epistles  worth  the  space. 
First,  I  want  to  apologize  to  several  writers 
whose  articles  did  not  appear  in  this  issue.  Be 
assurred  that  they  HILL  make  it.  Update  is 
blessed  with  excellent  article  support  by 
outstanding     writers.  I  appreciate  your 

contributions  and  I  know  that  the  subscribers  do 
also.  So,  KEEP  THEM  COMING.  Your  articles  HILL 
be  published. 


I  was  talking  with  Larry  Kenny  T'other  late 
night  and  ask  him  a  question.  Larry  came  back 
with,  "Its  in  your  own  magazine",  and  "dont  you 
read  Update?".  (Arrugh!).  This  issue  of  Update 
gives  me  great  problems.  Bill  Cable  came  in  with 
over  20  pages  of  articles  about  the  QL,  and  ALL 
about  things  that  I  dont  know  about!  So,  INDEED 
I'll  have  to  read  and  study  Update!  Al  Feng  and 
his  Networking  will  take  some  time  to  digest,  but 
most  of  all  it  will  take  "DOING  AT  IT".  And  there 
is  ole  Harren  Fricke  trying  to  teach  me 
polynomials!  I  think  that  I  "used  to  know  that" 
sometime  in  the  distant  past.  Gotta  study! 


October  1989 


2,5 


Update  Magazine 


Update  Magazine 


October  1989 


5  REM   **    "G-llfl",    7-18-89,  UF 
10  REM   **   GRRPH   Of    a  POUER 

EQUATION 
20  PLOT  0.86:    DRRU   ©,-86:  DRRU 
255,0:    DRRU   0,36:    DRRU  -255,0: 
DRRU  0,39:    DRRU  255,0:    DRRU  0,-S 
9:    PLOT  130.0:    DRRU  0,175 

4-0  FOR  n=26  TO  146  STEP  20:  PL 
OT  129. n:    PLOT   131, n:    NEXT  n 

50   FOR  n  =30  TO  230   STEP  20:  PL 
OT  n,37:    PLOT  n,S5:    NEXT  n 
60  PRINT  RT   1,1;  "GRAPH  Of.. 
Y "  ;  AT  12  ,  30 ; "        §>  ,. .  fly  ±& 

17;"-100":    REH~»*  Y-SCALe' 

sffl^WMJMIq  ,2;  "  -10"  ;  RT  10,23 

J "410":    REM   **  X-SCRLE 
_  ^  ^ 

|H  =  10 

=-10  TO   10   STEP    . 1 
L  =2  * X  *X  * x  + 1 1  * x  * x  - 3 1  *x  - 1 


1001 

1101 
1201 
1301 

80 

135  IF  RBS  <y*U)  >85  THEN  GO  TO 
150 

14-0   PLOT   X*H  +  130,y*U  +  86 
150   NEXT  x 


5  REM   **    "G-11B",    7-18-S9  ,  UF 
10  REM   **   GRAPH   Of    a  POUER 

EQUATION 
20  PLOT  0.85:    DRRU  0,-86:  DRRU 
255.0:    DRRU   0,66:    DRRU  -255,0: 
DRRU '0,39:    DRRU  255,0:    DRRU  0,-S 
9 :    PLOT   130 . 0 :    DRRU   0 , 175 

4-0  FOR  n=26  TO  146  STEP  20:  PL 
OT  129, n:    PLOT  131, n:    NEXT  n 

50  FOR  n=30  TO  230   STEP  20:  PL 
OT  r.  ,37:    PLOT  n,85:    NEXT  n 
60  PRINT  RT  1,1; "GRAPH  Of.. 
Y";  AT  12,30.:  "X" 
70BBBfflaBai5  ,  17;  "+2" ;  AT  16,  17 
; "-2":    REM   **  Y-SCRLE 

80BH8BMi3,2;"-5";flT  10, 26; 

"+5":    REM  ■**  X-SCRLE 


fj  =20 
|H=20 

l<  =-2  TO  2  STEP  .01 
iy  =6* x  *x  *x  *x  +5*x  *x  *x  -5*x 


j ammaDai3 , 1 ;  "Y  =  2Xt  3 

Xt2   -   31X   -  130" 


1001 

1101 

1201 
1301 

*X-5*X- _ 

135  IF  RBS  (y*U)  >85  THEN  GO  TO 
150 

140  PLOT  X*H+130 , y *U  +  86 
150   NEXT  X 

200ESSE9EH13 ,  l;  "Y  =  6X1-4  +  5X 
t3   -  5Xt2   -   5X  -1" 


GRAPH  Of..  Y 
Y   =  2X1-3   +  HXti 

-10 

2   -   31X   -  130 
+  100  * 

+  10 

 1  '  *7 \  ' 

X 

-100 

GRAPH  Of..      •  Y 
Y   =  6X1-4   +   5X  +  3 

-5  :| 

-   5X1-2    -   5X  -1 
+2 

+  5 

X 

i.  : 
',-2 

1  ; 

>  : 

\  i 

FIGURE  2 


FIGURE  3 


GRAPH  Of..  Y 
Y    =  2X13   +  HXt 


partial  Graph 


-   31X   -  130 

+10 


FOR  SALE-  QL  and  TS-2068  Items 

TS-2068  TOS  DISK  DRIVES,  AMDEX  DRIVES,  TOS 
CONTROLLERS  AND  POWER  SUPPLIES,  3"  Diskettes. 
SINCLAIR  QL  COMPUTER  and  other  Misc.  TS-2068  and 
QL  Items.  For  list  and  price,  send  SASE  or  Call: 
Stan  Light,  PO  Box  13,  Ellington,  FL  34222.  Tel: 
813-747-5833. 


2,6 


FIGURE  4 

October  1989 


Upoatc  Magazine 


Update  Magazine 


October  1989 


WOOD 


W  I  NJ2> 


COMPUT  I  2STO 


Bill  Cable 


RR  2  Box  92 


Cornish,    HH  03745 


603  675  2218 


CABLE  COLUMN 


This  issue  of  UPDATE  initiates  me  as  the  QL  Editor.  I  am  happy  to  assist  Bill 
Jones  in  producing  this  magazine  so  important  to  North  American  QL  users. 
Late  summer  is  a  very  busy  time  for  me.  Have  to  prepare  for  winter.  I  hope  to 
be  able  to  put  more  time  into  the  job  in  the  next  issue.  It  is  important  that 
we  get  maximum  participation  from  the  QL  base  we  have.  Ve  have  QL  users  at 
all  levels  of  expertise  and  with  many  different  configurations  of  equipment. 
As  editor  I  want  to  provide  something  for  everyone  and  a  lot  for  most.  My 
background  is  mostly  with  computer  software  and  even  then  there  is  a  lot  I 
don't  know.  I  hope  I  will  get  help,  advice,  criticism  from  readers.  I  would 
like  programs  to  print  for  readers  to  type  in.  I  would  also  like  to  print 
reviews  of  hardware  and  software.  And  tips  about  perks  and  quirks  of  the  QL. 
Also  I  need  to  know  what  readers  want  to  see.  One  quality  of  UPDATE  that  I 
like  is  its  friendly  non  pretentious  flavor.  Ve  all  have  a  lot  to  learn  about 
using  our  QLs  more  effectively  and  UPDATE  is  a  forum  for  doing  it. 

The  first  computer  I  ever  owned  was  a  QL  that  I  bought  in  1986.  So  I  am 
relatively  new  to  personal  computing  and  Sinclair  computers.  I  have  a  degree 
in  mathematics  (1967,  University  of  Florida).  That  was  before  computer 
courses  were  offered  on  campus.  But  my  various  jobs  led  me  into  computer 
programming.  Mostly  in  FORTRAN  on  DEC  machines  but  also  in  BASIC  at  Dartmouth 
College  (the  birthplace  of  BASIC).  I  got  burned  out  programming  for  others  by 
1980  and  started  a  cabinetry  shop.  But  I  wanted  to  get  back  into  computing 
for  myself  on  a  part  time  basis  and  started  looking  around  for  a  computer. 
Having  limited  resources  I  was  attracted  to  the  QL.  It  was  selling  for  $150 
when  I  bought  my  first  one.  I  was  quite  impressed.  I  felt  like  I  had  almost 
as  much  power  as  I  did  on  the  large  computers  I  used  to  work  on  and  a  much 
nicer  language  and  operating  system  to  work  with.  The  PSION  programs  that 
came  with  it  were  very  good  also.  Being  so  close  to  A+  (source  of  all  US  QLs) 
I  became  a  dealer  and  sold  QL's  locally  and  worked  with  several  businesses 
writing  custom  ARCHIVE  programs  for  them.  Then  I  started  selling  my  software 
nationally  on  my  own,  through  Peter  Hale's  EMSOFT,  and  finally  as  issue  disks 
for  UPDATE. 

Writing  software  takes  an  enormous  investment  in  time  up  front.  You  have  to 
have  it  before  you  can  sell  it.  Writing  major  pieces  of  software  for  the 
North  American  QL  market  stands  little  chance  of  much  financial  success  and 
so  has  to  be  done  during  spare  time.  Active  QL  users  probably  number  less 
than  2000.  That  is  a  pretty  small  number  to  write  software  for.  I  would  like 
to  make  a  request  to  all  QL  users  for  all  of  us  writing  software  for  North 
America  (Peter  Hale,  Bob  Hartung,  Al  Feng,  David  McCall,  myself,  and  others). 
Please  consider  our  software.  Get  a  catalog  from  EMSOFT  and  check  out  the 
advertisements  and  issue  disks  descriptions  in  UPDATE.  See  what  we  have  to 
offer.  We  are  trying  to  provide  a  service  to  QL  users.  We  have  the  ability  to 
write  software  as  good  as  any  coming  from  overseas.  We  all  do  this  on  the 
side  but  could  put  more  energy  into  it  if  we  had  more  financial  success.  You 
have  one  great  advantage  in  dealing  with  us.  We  can  be  contacted  by  mail  or 
phone  about  our  software  and  can  respond  to  your  specific  problems.  We  not 
only  sell  programs  but  are  interested  in  helping  all  QL  owners  get  the  most 
from  their  computers.  And  we  are  definitely  doing  it  out  of  love  for  the  QL 
and  not  for  the  money. 


BOOTING  UP  :   Programs  to  help 

In  the  description  below  I  will  use  '  mdvl_'  in  the  description.  Those  with 
floppy  drives  can  substitute  '  f lpl_V . .  Each .  t  ime  we  turn  on  our_QL  or  reseJLJLt 


October  1989 


27. 


Update  Magazine 


Update  Magazine 


October  ia«9 


we  have  a  chance  to  boot  up.  Load  a  program  from  mdvl_  called  'boot'  which 
gets  things  going.  So  a  boot  program  is  a.  SUFERBASIC  program  named  'boot' 
that  automatically  starts  a  more  complex  (usually  executable  machine  code) 
program(s).  All  we  have  to  do  is  press  <F1>  or  type  • lrun  mdv l_boot< ENTER > . 
The  PSION  programs  (QUILL, ARCHIVE,  ABACUS, EASEL)  have  boot  programs  like 
this.  The  real  PSION  machine  code  programs  are  called  qlwp,  qldb,  qlss.qlbg 
and  each  cartridge  has  a  boot  program  which  starts  execution  of  the  machine 
code.  Often  it  would  be  more  convenient  if  we  did  a  few  things  :  set 
time/date,  activate  a  toolkit,  load  speedscreen,  etc  before  starting  the 
program.  Everyone  should  make  sure  the  time/date  is  correct  at  boot  up.  It  is 
irritating  to  start  a  program  that  makes  use  of  the  time/date  only  to  find 
that  it  is  wrong  and  we  can' t  set  it  from  within  the  program.  Toolkits  and 
disk  interfaces  often  time/date  stamp  files  when  saved.  This  can  sometimes  be 
very  important  in  identifying  a  file.  The  TRUMPCARD/TK2  Toolkit  has  print 
buffering,  'hot  key'  screen  dump,  and  'hot  key'  macro  capability  plus  much 
more.  Ve  should  set  these  features  on  boot  up.  Many  of  you  may  wonder  what 
are  these  toolkits  everyone  talks  about.  They  are  extensions  to  SUPBRBASIC 
and  QDOS  that  give  new  useful  commands  or  make  corrections  to  ROM  bugs.  They 
may  be  on  ROM  or  in  the  disk  Interface,  or  loaded  into  RAM  at  start  up.  It 
usually  takes  some  action  on  our  part  to  activate  them.  Usually  the  best  time 
to  do  that  is  at  boot  up  time.  Depending  what  program(s)  we  will  be  running 
we  will  want  various  toolkit  features  initialized.  It  usually  makes  sense  to 
reboot  upon  quitting  a  program  unless  multitasking  or  saving  files  in  RAM 
disk.   The  system  is  'clean'   after  a  reboot. 

The  programs  described  below  should  be  helpful  to  all  configurations  of  QLs. 
You  incorporate  them  on  the  microdrive  of  the  program  you  want  to  boot  up  on. 
Each  of  the  PSION  microdrives  for  instance.  The  current  boot  program  on  your 
microdrive  must  be  renamed  with  a  name  of  your  choice  (or  copied  to  new  name 
then  'boot'  deleted).  The  3  programs  described  below  then  need  to  be  copied 
over.  They  will  help  you  easily  set  the  time/date  and  activate  your  toolkit 
if  your  have  one.  In  this  instance  I  used  some  of  the  features  of  my  TRUMP 
CARD/TK2  system  and  microdrive  version  of  speedscreen  to  illustrate  a  QUILL 
application.  If  you  have  a  different  toolkit,  no  toolkit,  no  cartridge 
speedscreen,  or  a  different  program  to  set  up  for  you  can  adapt  the 
initializing  portion  of  the  boot  program  (lines  1170  to  1390)  to  your  needs. 

I  tried  to  make  a  boot  up  system  that  can  be  easily  adapted  to  each  boot  up 
situation.  It  consists  of  3  programs  plus  your  own  boot  program  which  is 
renamed.   They  are  : 


1.  boot  initializes  tool  kit,   verifies  date,  merges 

last_date  and  date__set  If  needed,  starts  old 
boot  program  which  has  been  renamed. 

2.  boot_date_set  prompts,   sets,   saves  time/date 

3.  boot_last_date  stores  last  time/date  setting 

4.  (your  old  boot)  starts  up  your  program  as  it  use  to.  Just 

renamed.   On  your  QUILL  cartridge   (disk)  you 
could  rename  boot  to  boot_quill. 


This  boot  system  has  the  following  features  : 


1.  Quick  loading.   That  is  why  boot_date_set  is  only  merged  if  needed. 

2.  Single  key  presses  for  quick  entry. 

2.  Initialize   (activate  toolkit  features,   speedscreen) only  if  desired. 

3.  Force  time/date  set  if  out  of  range   (as  when  first  powered  up). 

4.  Verify  time/date  if  within  range   (as  after  a  reset). 


October 


2k 


ypaate  Magazine 


Update  Magazine 


October  1989 


5.  Use  standard  time   (am/pra)    instead  of  military  time  in  displays. 

6.  Loads  and  runs  a  preset  program  (your  original  boot  program). 


From  SUPBRBASIC  type  in  the  programs  as  listed.  Save  each  one  when  finished 
by  its  name.  The  line  numbers  of  boot  and  boot_date_set  should  not  overlap 
because  they  are  sometimes  merged.  You  need  to  have  a  full  screen  for  window 
#2  for  program  entry,  'window  #2,512,206,0,0  :  els  #2<EMTBR> '  will  take  care 
of  that.  If  you  don't  have  a  toolkit  the  best  .  way  to  start  is  'auto 
1000<EHTBR>' .    Vith  TK2  typing  » ed  1000<BHTBR>'   gets  you  going. 

After  the  3  programs  are  typed  in  and  saved  you  can  pick  a  program  to  use  it 
on.  QUILL  is  what  this  particular  code  is  set  up  for.  Take  your  copy  of  QUILL 
(not  the  original)  and  put  it  in  mdvl_.  Have  the  cartridge  of  the  boot- 
programs  you  just  entered  in  mdv2_.    Now  : 


copy  mdvl_boot  to  mdvl_boot_quiil<ENTER>  (rename  boot) 

delete  mdvl_boot <ENTER>  (delete  old  copy) 

copy  mdv2_boot  to  mdvl_boot <ENTER> 

copy  mdv2_boot_date_set  to  mdvl  boot  date  set<ENTBR> 
copy  mdv2_boot_last_date  to  mdvT_boo:E_las:E_date<ENTER> 

Now  you  are  all  set.  Pull  the  cartidges  out  reset.  Put  the  modified  QUILL  in 
mdvl_  and  press  <F1>.  If  you  find  there  is  not  enough  room  on  the  cartridge 
you  can  delete  CLONE,    INSTALLJ3AS,    CONFIG_J3AS  on  your  PSION  copy. 

If  you  are  using  a  different  program  besides  QUILL  then  substitute  its  name 
for  QUILL  and  changes  line  1040  of  boot  to  reflect  that  change. 


BOOT 

1000 
1010 
1020 
1030 
1040 
1050 
1060 
1070 
1080 
1090 
1100 
1110 
1120 
1130 
1140 
1150 
1160 
1170 
1180 
1190 
1200 
1210 
1220 
1230 
1240 
1250 
1260 
1270 
1280 


program  1 

REMark  BOOT 

RBMark    boot  program  :   initialise  too!  kit,  cheok/set  date.^tart  proS™ 


LET  boot_dev$  =  "mdvl_ 
LET  to_run$  ■  "boot_quill" 
LET  sys_ld$="MY  SYSTEM" 


LET  year 
LET  hour 


REMark  boot  device 

REMark  program  to  run  after  initial izinR 
REMark  your  identification  for  the  screen 


1989  :  LET  month  =  12 
16  :   LET  minute  =  30  : 


LET  day  =  20  : 
LET  second  «  0 


REMark    default  time/date 


LET  1=7. 88922 1E8 
LET  u=l. 104368E9 


REMark  1986  -  The  lower  limit  for  good  date 
REMark  1999  -  The  upper  limit  for  good  date 


OPEN  #l,con_512x206a0x0  :  OPEN  #2, con_512x206a0x0  :  CLS  #0 
K     .  JJ(.  REMark  querry  for  Initialization 

head  sys__id$  :   CSIZE  0,0  :   AT  2,55  :   PRINT  "for  :   » ;  to  run* 
boot  dev$  :   CSIZE  2, 1 


AT  3,55  :   PRINT  "On 


.  _   _'   *      w"      '        I  WUUL    uev*    ;  L 

AT  7,0:   CLS  4:   PRINT  "Initialize  [ y/n] 


LET  a$  =  I NKEY$ ( 
IF  a$=="y" 


l>   :   PRINT  a$! ; 


PAPER  0 


PAPER  7 
INK  7  : 


:  INK 
CLS  3 


:  PRINT  " 
CSIZE  0, 0 


AT  I0,3l 
AT  13, 31  : 

AT  14,26  : 
SDP_SET  1 

AT  15,29  : 


:  PRINT 
PRINT  ' 


key  press 


REMark    tk2_ext  initialization 
"-Initialization-" 
Activating  TK2_EXT"   :  TK2_EXT 

REMark    screen  dump  with  <ALT>d 
PRINT  "Setting  up  <ALT>d  screen  dump" 
1,0,0:   SDPJCEY  d 

REMark    print  buffer 
PRINT  "Setting  up  print  buffer"   :   PRT_USE  ser, ser 

REMark    some  altkey  (hot  keys  for  quill) 

2,9 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


1290  AT  16, 10 

1300  PRINT  "QUILL  HOT  KEYS  :    <ALT>p  -  prints,    <ALT>t  -  top,    <ALT>b  -  bottom" 

1310  ALTKEY   • p» , CHR$ <240)&CHR$ <112)&CHR$ (10)&CHR* <10)&CHRS <10) 

1320  ALTKEY   ' t * , CHR$ (240) &" G" &"T" 

1330  ALTKEY  » b» , CHRS <240)&» G' &' B* 

1340  PAUSE  200 

1350  REMark    Speedscreen  initialization 

1360  AT  17,31   :    PRINT  "loading  speedscreen  ..." 

1370  LET  x  =  RESPRC 11240) 

1380  LBYTES  boot_dev$&"speedscreen_code" , x 

1390  CALL  x 

1400  END  IF 

1410  REMark  if  date  within  limits  verify 

1420  LET  a$  =  "y"  : 

1430  IF  DATE> 1  AND  DATE<u 

1440  head  "VERIFYING  TIME  AND  DATE" 

1450  LET  d$=DATE$   s    LET  d  -  d$C13  TO  14)    :    LET  pS  »  "  am" 

1460  IF  d>ll   :    LET  p3  =  "  pm"    :    IF  d>12  :    LET  d  =  d-12  :    END  IF  !    END  IF 

1470  AT  4,5  :    PRINT  d$  <6  TO  lDMdSU  TO  4)  ;  !  !  !  DAY*!  !  !  d;  dS  <15  TO)  ;  p$ 

1480  PRINT  WVChange  time/date  C  y/nl    :    ";    :    PAPER  7   :    INK  0  :    PRINT  » 

1490  LET  aS  =   INKEYS<-1)    :    PRINT  a$!  ;      :    PAPER  0  :    INK  7  :    CLS  3  :    CSIZB  0,0 

1500  END  IF 

1510  REMark     merge  last  date,    time/date  setter  if  needed 

1520  IF  a$  =  "y" 

1530  AT  17,1:   PRINT  "Getting  last  date.    If  you  get  a  'not  found'   error  type  :" 

1540  AT  18,1   :    PRINT  TO  25j"lrun  " j boot_dev$ ; "boot_date_set<ENTER>" 

1550  MERGE  boot_dev$&" boot_last_date"   :    last_date   :    RBMark  get  last  date 

1560  AT  17,1   :    CLS  4   :    CLS  2  j    PRINT  "merging  " &boot_dev$&" boot_date_set  ..." 

1570  MERGE  boot_dev$&"boot_date_set"  :   REMark  merge  date  setting  procedures 

1580  date_set 

1590  END--  IF  . 

1600  REMark  start  program  if  any 

1610  head  "STARTING  A  PROGRAM"   :   CSIZE  0, 0 

1620  AT  10,1:   PRINT  "ENTER  device_program  to  start  t <ENTER>  =  "jto_run$;M]    : " » 

1630  INPUT  i*  :    IF  i$  =  ""   :    LET  i*  =  boot_dev$&to_run$  :    END  IF  :   CLS  :    INK  5 

1640  AT  6,1   :    IF  i$  =  ""   :    PRINT  "Done"   :   ELSB  :   PRINT  "lrun  " ; i*  :    BND  IF 

1650  IF  i$<>""   :    LRUN  i$  :    END  IF  :  STOP 

1660  : 

1670  DEFine  PROCedure  head(hS) 

1680  CLS  #1  :   CSIZE  2,1  :   PAPER  7  :    INK  0  :   AT  0,0  :   CLS  4 

1690  AT  0,20-LEN<h$)/2  :    PRINT  hS  :    PAPER  0  :    INK  7 

1700  END  DEFine  head$ 


BQOTJDATEJBBT 


program  2 


awu  year  =  iyey  :   LET  month  =  9  :  LET  day  -  20 

5060  LET  hour  -  18  :   LET  minute  =  30  :   LET  second  =  0 


9/89 


or 


5080  OPBN  #l,con_512x206a0x0  :  OPEN  #2, con  512x206a0x0 
5090  : 

5100  date_set  :  CLS 
5110  : 


October  1989 


3.0 


update  Magazine 


Update  Magazine 


October  1989 


5160 

5170 

5180 

5190 

5200 

5210 

5220 

5230 

5240 

5250 

5260 

5270 

5280 

5290 

5300 

5310 

5320 

5330 

5340 

5350 

5360 

5370 

5380 

5390 

5400 

5410 

5420 

5430 

5440 

5450 

5460 

5470 

5480 

5490 

5500 

5510 

5520 

5530 

5540 

5550 

5560 

5570 

5580 

5590. 

5600 

5610 

5620 

5630 

5640 

5650 

5660 

5670 

5680 

5690 

5700 

5710 


AT  16,20  ;    PRINT  "<space  bar>     toggles  to  next  time/date  field" 

AT  17,20  :    PRINT  "1  or  2  digit  number  also  works  with  auto  toggle" 

AT  18,20  :    PRINT  " <ENTER>     when  time  and  date  are  correct" 

AT  6,15   :    PRINT  "Date" ; TO  40; "Day"; TO  59{"Time" 

AT  0,20   :    CSIZB  2,1   :    PRINT  "SETTING  DATE  AND  TIME" 

REPeat  prompt _loop 

setter  minute ,  31 ,  0,  59 

setter  hour, 28, 0,23 

setter  day, 14, 1,31 

setter  month, 10, 1 , 12 

setter  year, 7, 1962, 1999 

setter  second, 34, 0, 59 

IF  what  ■  10  s   EXIT  prompt_loop  :    END  IF 
END  REPeat  prompt_loop 
CSIZE  0,0  :  date_save 
END  DEFine  date  set 


a/date  prompter 


IF  what=216: 
IF  what=192: 
IF  what*200: 


REMark  actual  tin 
DEFine  PROCedure  setter (value , col , min, max) 

IF  what  =  10  :   RETurn  :   END  IF  :   REMark  <RETURN>  key  means  no  more 

REPeat  setterloop 

SDATE  year, month,  day,  hour,  minute,  second 
display_date  :    CSIZE  2,  1   :    AT  5, col   :    PRINT  "" 
LET  what  -  CODB  < I NKEYS <- 1 ) ) 
IF  what=208:   LET  value=value+li    END  IF 
LET  value=value-l:    END  IF 
LET  value=rain:   END  IF 
LET  value«max:   END  IF 

REMark  see  if  numeric  entry 

IF  what>47  AND  what<58 
LET  what=what-48 
LET  what2«CODB(INKEY$<100>> 
IF  what2  =  0 
LET  value=what 
IF  max  =  23  AND  p$  =  "  pm" 
IF  min  »  1962  j   LET  value  = 
LET  what  =  32 
ELSE 

IF  what2>47  AND  what2<58 
LET  what2  =  what2  -  48 
LET  value  =  10* what  +  what 2 

IF  max  *  23  AND  p*  =  "  pm"  :   LET  value  -  value  +  12  j   END  IF 
IF  min  =  1962  :   LET  value  *  1900  +  value  s   END  IF 

 LET  what. -a  32  ^REMark-advance  to-ne^ty^ne-dato  field 

END  IF 
END  IF 
END  IF 

IF  value>max: 
IF  value<min: 


REMark  up  arrow 
RBMark  down  arrow 
REMark  left  arrow 
RBMark  right  arrow 


:   RBMark  wait  a  little  for  2nd  digit 

:   REMark  no  2nd  digit 

:    LET  value  »  value  +  12  :   END  IF 

value  +  1990  ;   END  IF 

:   REMark  advance  to  next  time/date  field 


RBMark  check  for  2nd  digit 


LET  value=max: 
LET  value=min: 


END  IF 
END  IF 


IF  what  =  10  OR  what  * 
AT  5, col   :    PRINT  "  " 
BND  IF 
END  RBPeat  setter_loop 
BND  DEFine  setter 


RBMark  check  if  too  large 
RBMark  cheok  if  too  small 
RBMark  <spaoe>  or  <RBTURN> 


3.1 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


5720 
5730 
5740 
5750 
5760 
5770 
5780 
5790 
5800 
5810 
5820 
5830 
5840 
5850 
5860 
5870 
5880 
5890 
5900 
5910 
5920 
5930 
5940 
5950 
5960 
5970 
5980 
5990 
6000 
6010 
6020 
6030 
6040 
6050 
6060 
6070 
6080 
6090 


REMark  saves  new  date  parameters 

DEFine  PROCedure  date_save 

AT  14,0  :    CLS  2  :    AT  18,1   :    PRINT  "saving  new  date 

DELETE  boot_devS&"boot_last_date"  :    RBMark  delete  old  file 

OPEN_NEV  #3, boot_devS&"boot_last_date"  :    REMark  open  new  file 

PRINT  #3, "9000  DEFINE  PROCedure  last_date"  :    REMark  write  procedure 

PRINT  #3,  "9010       let  year="  ;  year;  ":  let  month="  ;  month;  ":  let  day88"  ;  day 
PRINT  #3, "9020       let  hour=" ; hour ;": let  minute="  ;  minute;  ": let  second=" ; 0 
PRINT  #3, "9030      sdate  year , month,  day,  hour , minute, second" 
PRINT  #3, "9040     END  DEFine  laet_date" 
CLOSE  #3 
END  DEFine  save_date 
:  RBMark  display  time/date  cleary  in  am/pm 

DEFine  PROCedure  display_date 

CSIZB  2,1  :  LET  dS  =  DATES  :  LBT  tS  =  dS(13  TO)  :  LET  dS  =  dS  (1  TO  12) 
LET  t  =  tS<l  TO  2):  LET  pS  =  "  am":  IF  t  >  11:  LET  pS  =  "  pm"  :  BND  IF 
IF  t  >  11 

LBT  pS  =  "  pm"    :    IF  t  >   12   :    LET  t$  =    (t-12)&t$(3  TO)    :    END  IF 


LET  tS 


"&tS 

&tS<2  TO)    :    BND  IF 

4  :    PRINT  dS;    :    AT  4,27   :    PRINT  tSjpS 


IF  LENUSX8 
END  IF 

IF  t*(l)="0"    :      LET  tS  =  "  ' 
AT  4,19   :    PRINT  DAYS   :    AT  4, 
CSIZB  0,0 
END  DEFine  display_date 
.  *  REMark  makes  centered  screen  headings 

DEFine  PROCedure  heading (headS) 

CLS  #0  :    CLS  #1   :    CSIZB  2,1   :    PAPER  7  :    INK  0  : 
AT  0, 20-LEN (headS) /2   :    PRINT  headS   :    CSIZB  0,0 
BND  DEFine  heading 

RBMark  prompts  until  y(Y)  or  n<N)  typed 

DBFine  FuNction  yorn<l,qS) 


AT  0,0   :    CLS  4 
PAPER  0   :    INK  7 


RBPeat  loop 

AT  1,0  :   CLS  4  :    PRINT  qS;"  £ y/nl 
LET  aS  =  INKEYS(-l)    :    PRINT  aSI ; 
IF  aS=="y"   :   RETurn  1   :    END  IF 
IF  aS=="n"   :    RETurn  0  :    END  IF 
BND  REPeat  loop 
END  DEFine  yornS 


";  :  PAPER  7  :  INK  0  5  PRINT 
PAPER  0  :    INK  7  :    CLS  3 


BOOT_LAST_DATB  program  3 

9000  DEFine  PROCedure  last_date 
9010       LET  year=1989: LET  month=9:LET  day=24 
9020      LET  hour=6:LET  minute=46: LET  second=0 
$030      SDATB  y**r ,  montb ,  day ,  bow ,  mlwst« ,  Becoud 
9040     END  DEFine  last_date 


Comments  on  programs  : 

BOOT  is  pretty  straight  forward.  Lines  1030  and  1040  should  make  sense  for 
your  device  and  new  boot  program  name.  Lines  1170  to  1390  need  to  also  apply 
to  your  system  tool  kit  and  desires.  Remove  and  alter  as  desired.  You  can 
always  skip  that  section  by  answering  • n'  to  the  initialize  question.  At  line 
1420  the  system  clock  function  DATE  returns  the  date  in  seconds  which  is 
compared  to  the  lower  and  upper  bounds  set  at  lines  1100,1110.  If  the  date  is 
not  sensible  the  BOOT  SET_DATE  routine  is  merged.  Otherwise  you  are  asked 
whether  the  date  is  correct.  After  the  date  is  okay  you  just  hit  <BNTBR>  to 
start  the  SUPERBASIC  program  set  at  line  1040  or  you  can  enter  something 
different. 


3.2 


October  1989 


l!pdate  Magazine 


Update  Magazine 


October  1989 


BOOT  SET  DATE  is  set  up  so  it  will  run  as  an  independent  program.  You  may 
have"to  "run  it  that  way  if  the  BOOT_LAST_DATE  file  gets  lost,  normally  it 
will  be  merged  with  boot  when  needed.  Of  interest  is  the  call  from  date_eet 
to  setter  for  each  part  of  the  date.  The  way  SUPERBASIC  works  is  that  the 
variable  'minute'  gets  passed  to  'value'  (see  how  they  correspond  in  the 
argument  list).  The  value  of  'minute'  in  date_set  upon  return  is  whatever 
•value'  was  set  to  in  setter.  I  use  some  slicing  and  concatenation  to  get  the 
date  in  the  desirable  form  in  display_date.  Procedure  date_save  is 
interesting  in  that  it  create  a  file  writes  a  procedure  to  it  that  can  merged 
to  boot  if  needed.    This  is  a  technique  that  can  be  very  useful 1. 

BOOT_LAST_DATE  is  written  by  BOOT_DATE_SET  except  the  first  time  when  your 
write  it. 


QL  JTBTVQRKing 

by  Al  Feng 

Claims  abound  for  computer  hardware  and  software.     The  original  claims  for 
SINCLAIR'S  QL  (aka  ZX-83)  promised  the  capability  of  a  PEER/PEER  NBTWORK  because 
the  QL  had  been  designed  for  use  in  a  "business"  environment.     The  two  'NET' 
ports  bear  witness  to  this  intent.      In  a  PEER/PEER  NETWORK  each  QL  would  have 
the  capability  of  sharing  data  and  devices  equally  (therefore,   as  a  "peers"). 

Reality  interferes  with  claims  (design?)  and  a  standard  QL  is  a  stand  alone 
computer.     It  is  generally  conceded  that  there  are  limitations  in  the  standard 
QL  firmware  (i.e.,   QDOS)  which  makes  PEER/PEER  NETWORK ing  difficult,    if  not 
impractical  and/or  impossible.     This  may  yet  be  a  matter  of  poor  communication 
by  those  who  have  claimed  to  have  NETWORKed  several  QLs  together  using  ' NETi (n) ' 
and  'NETo(ut)'    in  the  way  of  bad  or  incomplete  examples.   Regardless,    I  have 
tried  many  attempts  at  establishing  a  NETWORK  using  two  QLs  using  'NETi'  and 
•NETo'   to  no  avail. 

Regardless,    it  is  possible  to  NETWORK  several  Sinclair  QLs  via  a  dedicated 
FILE-SERVER/CLIENT  NETWORK.     This  is  made  possible  by  the  multi-TASKing 
capabilities  of  the  QDOS  operating  system  with  the  assistance  of  SuperTOOLKIT 
coding  on  each  participating  QL   (both  authored  by  Tony  Tebby) .  Occassional 
explanations  of  how  this  has  been  performed  has  been  published  in  various 
magazines  and  newsletters.      Most  have  been  oblique. 

At  a  recent  meeting  of  our  local  user  group  (Chicago  Area  Timex     User  Group  / 
CATUG)  a  QL  NETWORKing  demonstration  was  performed  for  the  benefit  of  those  who 
hadn't  seen  it  before.     Constraints  of  physical  space  precluded  linking  more 
than  two  QLs  together;   but,   as  many  as  63  CLIENTS  may  be  "serviced"  by  a  single 
SERVER. 

There  are  practical  constraints  to  employing  any  NETWORK.      If  the  FILE-SERVER  is 
pre-occupled  with  another  CLIENT  then  access  will  be  delayed  until  the  first 
CLIBNT  is  serviced.     The  more  CLIENTS  attempting  access,   the  slower  the  service. 
The  specifications  indicate  that  as  many  as  eight  F I LE-SERVERs  may  be  active  on 
a  QL  NETWORK  at  any  given  time. 

In  a  QL  NETWORK,  each  computer  active  on  the  NETWORK  is  assigned  a  ' NET (work), 
number'    (e.g.,    'net  1').     NETWORK  'numbers'   are  assigned  arbitrarily,   with  the 
only  proviso  being  that  two  QLs  not  have  a  duplicate  'NET  numbers.' 

33 


October  1989 


Update  Magazine 


Update  Magazine   _^  October  1989 


It  is  generally  espoused,    based  on  "other"   LOCAL  AREA  NETWORKS  (LAN) 
implementations,    that  the  QL  with  the  most  hardware   (e.g.,   a  hard  disk,  floppy 
disk,   printer,   etc. )  attached  act  as  the  FILE-SERVER.     The  "first"  computer 
(Butch' s)  was  fully  configured  with  a  TRUMP  card  running  dual  720K  5.25"  disk 
drives.      The  "second"  computer   (Steve's)   was  a  128K  QL  to  which  a  SuperTOOLKIT 
eprom  was  attached  via  the  'ROM'  port. 

To  implement  the  NETWORK  the  following  commands  were  typed  into  each  computer 
C<ENTER>'    indicates  that  the  ' ENTER'   key  was  pressed  after  entering  the 
preceding  statement): 

(BUTCH' s  QL)  (STEVE'S  QL) 

NET  1     <ENTER>  NET  2  <ENTER> 

FSERVE  <ENTER>  NFS_USE  flp,    nl_flpl_,    nl__flp2_  <ENTER> 

The  "FSERVE"  statement  which  is  entered  indicates  that  this  QL's  function  within 
the  NETWORK  is  to  act  as  a  FILE-SERVER. 

The  multiple_statejnejat„I^^^  .thai  .you  .want  any 

calls  made  to  using  ' f lpl_'   and  ' f lp2_'   be  answered  by  the  computer  which  was 
assigned  'NET(work  number)   1'   by  the  devices  specified  in  the  second  and  third 
part  of  the  statement.      In  this  instance,   we  wanted  a  call  to  '  f lpl_'   to  be 
answered  by  ' f lpl_'    on  the  QL  wich  was  assigned  a  'NET(work  number)   1';  and 
similarly,   any  calls  to  ' f lp2_'    by  the  client  would  access  ' f lp2_'   of  the  QL 
whose  address  was  'NET  1'.      If  a  disk  drive  interface  had  been  attached  to 
Steve's  QL,    then  it  would  have  been  made  dormant  by  the  "NFS_USB  flp"  statement. 

The  computers  were  connected  with  a  shielded  cable  having  1/8"  microphone  Jacks 
(included  with  the  QL)  via  the  NET  ports  located  next  to  the  POWER  socket.  If 
we  had  wanted  to  connect  more  QLs,   we  would  have  indicated  a  • NET  number'  (eg., 
NET  3)  for  the  CLIENT  followed  by  the  NFS__USE  statement.     Alternat iveily,  we 
could  have  accessed  Butch' s  RAM  disks,   or  microdrives  (limited  to  a  choice  of 
two  of  any  combination). 

After  establishing  his  QL  as  the  FILE- SERVER,   Butch  loaded  in  a  copy  of  the 
Psion  XCHANGE.     A  copy  of  QLSS  from  one  of  Butch' s  disks  was  LOADed  i.uto  Steve's 
QL. 

LOADing  via  the  NETWORK  was  much  slower  than  direct   (dedicated)  access  to  the 
disk  drives.     There  are  at  least  two  reasons  for  this.     First,   communication  is 
done  at  a  rate  of  "only"  19,200  baud.     And,   secondly,   the  transmission  is  not 
continuous  because  the  SERVER  is  periodically  checking  for  "other"   input.  That 
is,   the  NETWORK  is  being  multi-TASKed  along  with  SuperBASIC  and  whatever  else 
the  user  may  have  EXEC  d  on  the  FILE-SERVER. 

Multi-TASKing  tends  to  slow  effective  program/TASK  speed.      In  part,    this  is 
because  each  TASK  is  given  a  priority  number  between  0  (off)  and  127  (maximum), 
with  32  being  the  "standard"  priority  given  to  either  SuperBASIC  or  an    BXEC_W' d 
program.      It  appears  that  background  TASKs  are  suspended  by  the  operatiajr 
system.  * 

While  the  "server  priority"  appears  to  be  '8',    the  SERVER  must  constanty  monitor 
the  NETWORK  for  any  communication  from  CLIENTS  and  allow  access  to  its  I/O 
storage  devices.      In  effect,   we  "disabled"  Butch' s  QL  while  we  were  accessing 
his  drives;   and,    it  seemed  to  be  moderatlely  "crippled"  for  normal  use. 

NETWORKing  on  the  QL  clearly  has  some  drawbacks.     But  it  should  be  noted  that 
this  "crippling"  effect  occurs  in  all  LOCAL  AREA  NETWORKS.      In  the  non-SINCLAIR 
world,  a  single  computer  is  often  dedicated  to  the  TASK  of  being  the  F I LE-SERVBR 
(eg.,   a  mainframe,   a  minicomputer,   or  80286/1386DX/1486) .     This  should  be  taken 
as  the  model  for  QL  NETWORKing,   also,   whereby  a  single  QL  is  dedicated  to  the 
task  of  acting  as  the  FILE-SERVER,   with  other  QLs  acting  as  CLIENTS.  This 

3M 


October  1889 


Update  Magazine 


Update  Magazine 


October  1989 


becomes  a  valid  application  when  several  computers  wish  to  share  a  common  source 
of  data  (i.e.,  from  a  hard-disk).  Use  of  a  NETWORK  as  illustrated  appears  to  be 
impractical  for  "home"  applications. 

The  following  SuperBASIC  program  may  facilitate  implementing  multiple  CLIENT 
stations  in  a  FILE-SERVER/CLIENT  NETWORK: 

10  WINDOW#0,448,52,40,204:    PAPER#0 ,7:1 NK# 0 , 0 

20  WIND0W#1,  512,  256,  0,  0:    WIND0W#2,  448 ,  226,  40,  3r0 

30  CLS:    PAPER  7:    INK  0:    INK#1,3:    CSIZE  0,0 

40  PRINT#0\, '[    ';VER4;'    ROM  ]    ';   \,    FREE_MEM; '  bytes' 

50  CSIZE  2,  1 

60  INPUT,  WWW,  "NETWORK  STATION  NUMBER:      »» ;a$:   NET  aS 

70  NFS_USE  flp,    nl_flpl_,  nl_flp2_ 

80  CLS:    INK  37:    PRINT,  WWW,    "NETWORK";:    INK  0: 

PRINT  "   CLIENT  STATION";:      INK  2:PRINT"    <  ";:INK  0: 
PRINT  a$;:INK  2: PRINT  "  >" 
90  FOR  n=0  TO   (a$-l):BEEP  250,10   : PAUSE  8: NEXT  n 
100  REMark  *******  CLIENT   (PLATYPUS  Software  1988)  ********* 

SAVE  this  program  as  either  BOOT  or  CL I ENT_BAS .      If  you  have  a  hard-disk,  then 
you  may  wish  to  change  line  70  to  read: 

70  NFS_USE  flp,    nl_flpl_,    nl_hdkl_  (?) 

to  access  the  hard-disk  when  a  call  to  ' f lp2_'    is  made  by  the  CLIBNT.     Line  90 
provides  an  audible  confirmation  of  the  station  number.     The  program 
"terminates"  with  the  active  cursor  in  •wlndow#0'.     Either  LOAD  your  regular 
boot  when  this  appears,   or  add  a  line  which  reads: 

95    LRUN/EXEC_W  f lpl_ProgramName 

where  « ProgramSame"    is  jjhSLJMNm  of.  thS-JSTj^caja^  givan  

CLIENT  station  (substitute  ''EXEC_W'   for  '  LRUN'   as  necessary). 


FUDGING  TO  GET  A  PEER/PEER  NETWORK 

Since  up  to  eight  QLs  can  theoretically  perform  the  F I LB-SERVER  role  within  the 
NETWORK     it  is  possible  to  have  PEER/PEER  NETWORK  of  sorts  by  INPUTting  both  the 
NFS  USB' and  FSERVE  statements  on  each  QL.     What  you  may  end  up  with  is  'dueling 
devices' ,   and  a  potential  interruption  of  primary  keyboard  INPUT  while  someone 
attempts  to  access  one  of  your  devices. 

Screen  enhancer  code   (I  prefer  SPEEDSCREEN)   is  recommended  if  you  plan  to  use 
the  FILE-SERVER  as  an  active  terminal. 


"HOME"  USE  OF  QL  NETWORKing 

Okay.  You've  got  two  or  more  QLs  and  you've  got  SuperTOOLKIT  coding  on  at  least 
one  of  them.     But,   you  don't  have  a  hard  disk  (who  does?).     The  464  question  is: 

Is  NETWORKing  practical  enough  for  me  to  consider 
getting  a  second  SuperTOOLKIT? 

If  you  don't  even  have  a  SuperTOOLKIT,   is  a  possible  expenditure  of  more  than 
S100  for  the  NETWORKing  capability  money  well  spent?    Just  how  much  money  you 
should  spend  on  an  orphan  computer  depends  on  how  much  viability  you  feel  the 
operating  system  has  for  you  individually.     Had  Sinclair  Research  not  folded-up 
its  tent,   the  price  of  the  128K  QL  would  probably  be  more  expensive  than  the 

35 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


current  SI 00   (at  the  time  of  this  writing).      I  suspect  that  it  would  have  been 
plausible  that  the  ZX-84/85,    or  at  least  the  ZX-86  would  have  had  an  extended 
°??rarCng  svstem  "hi°h  would  have  incorporated  some  of  the  SuperTOOLKIT  coding 
with  the  128K  QL  persisting  as  do  the  8088/V-20  IBM  PC  clones.  - 

MostTP®°Pie  wno  have  SuperTOOLKIT  coding  (originally  available  as  "code"  which 
was  LRESPRed  into  RAM  as  well  as  the  standard  EPROM,    it  is  now  provided  on 
several  disk  drive  interfaces)  claim  that  they  wouldn't  live  without  out  it. 
2?f»  o2Sfr^UperT°°LKIT  codinS  Provide  besides  the  facility  to  expedite  a 
FILE-SERVER/CLIENT  NETWORK?     It  does  make  file  manipulation  and  SuperBASIC 
editing  more  convenient;    but,    it  is  not  a  necessity. 

If  you  already  have  the  hardware  Cor,   extra  cash  to  spend.'],    then  you  can  indeed 
set  up  a  viable  NETWORK  for  "home"  use  if  one  ignores  the  conventional  wisdom 
for  setting  up  a  LAN.      What  you  want  to  do  is  to  utilize  the  FILE-SERVER  only  as 
a  source  of  additional  memory  (as  with  "extended  memory"  for  MS-DOS)  which  is 
utilized  to  provide  extra  RAM  storage  via  RAM  DISKs. 

If  the  INPUT  into  the  two  QL's  inicated  in  the  first  part  of  this  article  had 
been  reveresed  then  the  QL  with  the  TRUMP  card  would  have  been  the  CLIENT,  and 
the  role  of  the  FILE-SERVER  would  have  been  taken  by  the  128K  QL. 

C    128K  QL  I  C    TRUMPed-up  QL  ] 

NET  1     <ENTER>  NET  2  <ENTER> 

FSERVE  < ENTER >  NFS_USE  mdv,    nl_raml_,    nl_ram2__  <ENTER> 

In  this  example,  since  the  128K  QL  did  not  have  disk  drives,  calls  were  made  to 
theoretical  RAM  DISKs.  Calls  to  » mdvl_'  and  •  mdv2_'  are  now  answered  by  'rami  • 
and  ,ram2_'    of  the  QL  with  the   ' NET  1»  assignment. 

Because  a  standard  QL  does  not  have  RAM  DISKing  capabilities,   extra  code  needs 
to  be  LRESPRed.     While  this  can  be  purchased,     code  to  provide  "static"  RAM 
DISKing  is  also  available  with  the  CHOice  program  code;   and,   "dynamic"  RAM 
DISKing  is  available  with  the  QRAM  program  code   (a  STATIC  RAM  DISK  needs  to  be 
formatted  whereas  a  DYNAMIC  RAM  DISK  does  not).     A  128K  QL  can  provide  a  STATIC 
RAM  DISK  of  about  80K,   or  160  sectors. 

This  doesn't  sound  like  a  lot,   and  it  isn't.     But,    if  you  have  any  additional 
memory  expansion  beyond  what  you  are  currently    using  on  your  primary  QL  than 
that  which  QDOS  is  capable  of  directly  addressing  then  it  can  be  implemented  by 
the  FILE-SERVER  for  the  STATIC/DYNAMIC  RAM  DISK. 

A  multiple  QL  configuration  utilizing  twin  512K  Expanderams  is  currently  being 
run  as  I   input  this  text  to  ensure  viability  of  the  concept  described. 
Essentially,    a  second  QL  with  a  512K  Expanderam  was  powered  up  in  addition  to  my 
normal  QL  which  has  an  512K  Expanderam  and  Cumana  disk  interface.      The  second  QL 

was  designated  as.. jthe  E ILE-SER VER . _    My.ragulaii^QL-was  designated         th«  CT.TRNT  

The  initial  statements  were  as  follows: 

C   512K  QL  3  C   512K  QL  with  CUMANA  I/F,    etc.  ] 

NET  1     <ENTER>  NET  2  <BNTER> 

FSERVE  <ENTER>  NFSJJSE  mdv,   nl_raml_,   nl_ram2_  < ENTER > 

DYNAMIC  RAM  DISK  code  used  on  the  FILE-SERVER  in  this  instance. 

If  I  had  a  third  QL  with  a  SuperTOOLKIT,    it  too  could  have  been  designated  as  a 
F I LE-SERVER  with  its  memory  being  utilized  as  a  RAM  DISK: 
NET  2  <ENTER> 

NFS_USE  mdv,   nl_raml_,   n3  rami  <ENTER> 


3.6 


October  1989 


Update  Magazine 


If  the  third  QL  also  had  a  512K  memory  expansion,    then  it  this  hardware 
co  ii^.-;,-Cu  -vjuj  -   pi       .  ce      <      k*  *I  e        -  of  about  547K  each    <  1094k  total)  in 
addition  to  whatever  memory  was  available  to  the  primary  QL!      However,  before 
you  run  to  the  phone  to  order  additional  hardware  one  should  note  that  this  may 
only  be  viable   if  one  already  has  the  extra  QL,    extra  memory,    et  cetera.  I 
suspect  that  configuration  is  lOT  price  competitive  with  the  MEGA- board.  Again, 
remember  that  you  are   limited  to  using  the  ''extra"   memory  as  RAM  disks. 

There   is  an  advantage   to  utilizing-  "external"   RAM  disks.      If  the  program  you  are 
working   locks  up  the  keyboard   Cit  happens),    you  will  not   loose  the  contents  of 
the  data  which  had  been  stored  In  RAM  when  you  RESET  the  computer.      Of  course , 
programs  and  data  stored  in  the  RAM  of  the  primary  computer  will  be  lost;  and, 
power  spikes  or  outages  will  result  in  a  loss  of  the  contents  in  any  RAM  disk. 

Two  things  are  clear  from  this  type  of  memory  expansion. 

The  first   is  that  one  has  to  get  used  to  making  f  calls'    to  ' mdvl_'    or  » mdv2_' 
for  the  extended  memory.      This  isn't  too  difficult;    but,    if  you  opt  for  this 
type  of  system  configuration  as  a  permanent  set  up,    then  you  may  want  to  modify 
a  majority  of  your  programs  to  look  to  '  radvl_J  /'  mdv2__*    for  data  storage.  [The 
DTK  AM  I C  SAM  DISKs  on  the  primary  QL  are  st  ill  referred  to  as   '  raml__'  /'  rain2_'  3 

The  second  mistake   I  notice  myself  making  is  that   if   I   "walk  away"   for  a  moment 
and  come  back,    I   often  begin  typing  on  the  "wrong"   keyboard.      This  Is  more  a 
matter  of  logistics,    and  can  be  resolved  by  a  number  of  options,  Including 
placing  the  FILE-SERVER  behind  the  CLIEIT,   or  simply  ' out  of  reach' . 

It    •  i  ,  *  ".  .   .       i      .  '  u*  one  of  it©  own  star,  ge  devices  to  the 

NFSJtfSE  statement  as  in  the  following  example: 

I   any  QL  3  C   any  other  QL  3 

JJET  1     <EKTER>  MET  2  <EMTER> 

FSERVE  < EETER>  KFS_USE  mdv,    nl_raml__,    n2_radv2_  <ENTBR> 

It  also  appears  that  "IFS__USE  ram"   is  does  not  appear  to  be  a  valid 
configuration.     A  request  for  another  QL*  s  RAM  would  seem  to  require  either  an 
" NFS__USE  mdv"  or  an  " HFS_USE  f Ip"  statement,    with  similar  devices  then  become 
inoperative  on  the  CLIEIT. 

The  IFS  USE  •;  '-a?,  anient  appears  to  have  some  limitations  which  are  not  flagged  by 
the  system.      In  tact,    7  have  found  that  there  is  more  flexibility  than  had  been 
immediately  eviderd       First  of  all,   the  EFS_USE  statement  made  be  made  to 
re     ^  I      «  v  t  ©I  en     ANY  designation.     You  can  theoretically  use  the  statement: 

IFS_USE  bozo,   nl_raml_,  nl_ram2__ 

The  difficulty  with  a  four  letter  device  name   is  that  you  may  CRASH  soma 
programs  which  are  only  looking  for  a  three  character  string.      So,    the  above 
"name"  should  be  truncated  to  "boz"  or  "bzo"  or  any  other  three  character  device 

Of  course  you  cai  use  a  more  reasonable  name  such  as  "fdk" ,  "rdk"  <?) . 
"Net"  might  be  a'  good  choice,  but  existing  keywords  are  invalid.  Remember  the 
assigned  designation  so  you  may  readily  access  it. 

The  EPS  USE  statement  may  be  changed   (several  times)   to  access  other  devices 
f  os.   o  .  cr  F  .  '  '  d«    ,"  s  as  needed, 

i  donft  have  a  current  application  for  utilizing  this  much  memory  since  I 

,  .  :  .  tc  iTs1  ~  _  *  more  than  two  programs  at  any  given  time;  and,  it 
may  late  ma  a  while  to  get  in  the  habit  LOADing  more  than  I  need.  Of  course, 
some  people  who  multi-TASK  their  programs  prefer  to  LOAD  all  of  them  in  at  once; 

5   hungr  y-...Xe*-g-_,-  BXCHAEGBX,-  — 


HAPPY  TRAILS,  &TSD  COMPUTING,  TO  YOU. 
October  1388 


37 


Update 


Update  Magazine 


October  1989 


STFJIG  SLICIHG,  COERCION  S  CONCATENATION 
Peter  Hale,  P.O.  Box  8763,  Boston,  MA  02114 

String  concatenation  is  a  subject  that  can't 
easily  be  covered  in  a  vacuum.  It  must 
include  string  slicing  and  coercion  as  well. 

A  good  starting  point  on  these  topics  is  in 
the  Concepts  section  of  the  QL  manual .  See 
coercion  on  page  11,  data  types  and 
variables  on  page  13,  slicing  on  page  46  and 
string  arrays/variables  on  page  5.1. 

What  follows  here  integrates  those  subjects, 

A  SuperBASIC  (or  Archive)  string  can  have  up 
to  32766  characters.  It  can  be  stored  as  a 
variable  if  the  variable  has  the  suffix  $. 

Any  of  the  256  characters  in  the  QL  charac- 
ter set  can  be  part  of  a  string,  although 
non-printing  characters  must  be  entered  as 
code.  Whether  entered  as  code  or  as  a 
printing  character,  each  character  requires 
only  one  space  in  the  string. 

In  SuperBASIC  each  character  in  a  string  is 
located  by  its  distance  from  the  first 
character.  In  the  string  a$=MabcdedghijH 
the  letter  "a"  is  in  first  position,  the 
letter  "j"  is  in  tenth  position,  As  in 
other  Sinclair  BASICS,  the  letter  V  is 
found  by  a$(l)  and  "j"  by  a${10). 

Other,  less  friendly  BASICS,,  make  you  use 
KIDS,  LEFTS  or  RIGKT$  functions  depending  on 
the  character's  position  in  the  string. 

SuperBASIC  string  slicing  is  elegantly 
simple,  The  syntax  of  string  slicing  is 
unchanged  whether  the  character  is  in  first, 
last  or  mid  position. 

Getting  more  than  one  consecutive  character 
out  of  a  string  is  similarly  straightforward 
and  simple.  The  syntax  is  a${  m  TO  a)  where 
n  is  the  position  of  the  first  character  and 
n  is  that  of  the  last.  Thus: 

a$(l  to  3)  gives  "abc" 

a${3  to  6)  gives  HdefM 

a$(7  to  7)  gives  V 

a${8  to  )  gives  Mhij" 

When  selecting  the  balance  of  a  string  it  is 
unnecessary  to  specify  the  position  of  the 
last  character. 


COERCION 

A  handy  feature  of  SuperBASIC  is  coercion. 
This  has  nothing  to  do  with  arm  twisting;  it 
means  that  a  number  can  be  represented  as  a 
numerical  variable  or  a  string  variable 
depending  on  the  kind  of  variable  defined, 
and  not  on  whether  or  not  there  are  quotes. 

If  you  set  the  variable  b=12,  it  will  be 
stored  as  a  number  variable.  On  the  other 
hand,  if  you  define  the  variable  b$=12,  it 
will  be  stored  as  a  string  variable  just  as 
if  you  had  written  b$="12". 

You  can  move  back  and  forth  through  the 
magic  of  coercion;  that  is,  b~b$  changes  the 
string  variable  b$  into  a  number  variable 
and  vice  versa. 

The  restriction,  of  course,  is  that  you  must 
deal  with  numbers .  Try  letting  a=a$  in  the 
above  example  and  you  crash.  It  is  also  a 
limitation  that  numbers  are  stored  accurate- 
ly only  to  eight  (8)  significant  digits 
because  it  is  all  done  in  floating  pdint. 

(Floating  point  -  a  digression:  This  means 
that  the  number  is  stored  in  two  bytes  as  a 
number  raised  to  the  power  of  10.  The 
second  byte  is  the  power  of  ten  to  which  the 
first  byte  is  raised. 

Thus,  b=123456:b$=b  returns  b$  as  "123456". 
Longer  numbers  are  handled  differently. 
c=1234567:c$=c  returns  cS  as  "1.234567E6"; 
d=12345S78:d$=d  returns  d$  as  "1.2345678E7"; 
e=12345S789:e$=e  holds  e$  as  "1 . 2345678E8" . 

Clearly,  b$  and  b  look  the  same.  c$  and  c 
and  d$  and  d  are  both  accurate,  although 
they  look  different  because  the  last  two 
characters  are  the  power  of  ten  to  which  the 
preceding  numbers  are  raised.  e$  and  e 
differ  because  the  ninth  digit  is  truncated. 

The  moral  for  using  coercion  is  to  stay  with 
numbers  under  9  digits;  for  clarity,  stay 
under  7  digits.) 

Coercion  tolerates  a  limited  mix  of  numbers 
and  text,  but  does  not  like  text. 

If  f$-R1234A",  coercion  allows  the  instruc- 
tion f=f$,  but  returns  f~1234.  It  will  not 
permit  coercion  of  g=MA1734M  since  the  first 


October  1989 


38 


Update  Magazine 


Update  Magazine 


October  1989 


character  is  not  a  number. 
COXC&TKRATIOI 

The  struggle  through  both  string  slicing  and 
coercion  helps  to  understand  the  full  poten- 
tial of  concatenation  in  the  Sinclair  QL. 

SuperBASIC  joins  two  strings  to  make  a  third 
with  the  operator  &  {Concepts  page  35). 

Whenever  SuperBASIC  sees  the  operator  &,  it 
knows  to  treat  whatever  variables  are 
involved  as  strings. 

Thus  i$=a$8i>$  or  x$=a$&b  will  each  return 
"abcdefghijl23456". 

If  the  operator  is  +,  SuperBASIC  knows  that 
it  should  to  do  an  arithmetical  operation. 

Whether  you  write  i=b+c  or  x=b$+c$  or 
x$=b$+c$,  the  answer  for  either  x  or  z$  will 
be  123456  +  1234567  or  1358023. 

x=a$+h,  or  x$=a$+b  will  crash  since  the  first 
character  in  a$  is  non-numeric  ('a'). 

Really,  that's  all  there  is  to  it,  although 
some  examples  (using  the  variables  in  the 
text  above)  may  help. 

1.  a$(8  to  9)&a$(4  to  5)="hide" 

2.  a$(2)&a$(9)&a$(7)=MbigH 

3.  b$+b$=246912 

4.  b$&b$=M123456123456M 

5.  a$(2)*b=Mb23456" 

6.  b${4)&b$(2)=M42"  but  b$(2)&b$(4)="24" 

7.  b$(4)tb$(2)=6  or  b$(2)+b$(4)=6 

8.  b${2  to  3)+b$(4  to  5)=68 

9.  b$(2  to  3)&b$(4  to  5)="2345" 

10.  y$=a${l  to  len(a$)-4):  z$=b$(4  to  5) 

y$&z$=Mabcdef45M 

11.  if  x$=a$5.b$="abcdefghijl23456M  then 

x$(4)&x$(9)&x$(7)&H  M&x$(12)&M  % 
x$(8  to  9)*x$(4  to  5)=  ? 

Just  don't  try  b(4)+b(5);  number  slicing 

doesn't  work.   Coerce  first,  then  be  gentle, 

applies  to  SuperBASIC,  but  not  to  life  in 
general . 


THE  QL  T  S  FORB  I  OJDEISf  BYTE 
—  Bob  Hartune  — 
Those  of  us  who  "cut  our  computer  teeth"  on  the 
ZX80/81  learned  quite  early  about  the  caveat  that 
accompanied  any  use  of  CHR$  118  when  machine  code 
was  stored  in  REMs .  Like  the  Cheshire  cat,  the 
line  could  disappear  right  before  your  eras  till 
nothing  was  left  but  the  grin!  The  problem  was 
that  this  particular  character  was  used  to  mark 
end-of-line  in  memory  as  well  as  being  the  new- 
line  (ENTER)  character. 

Shades  of  de-Ja  vous,  the  QL  has  done  it  again' 
with  CHR$(10).  but  the  matter  is  further  compli- 
cated by  the  manner  in  which  data  saves/loads  are 
done.  A  case  in  point  was  brought  to  my  attention 
by  Tom  Sutton  when  he  keyed  in  the  Mail  Pile 
listing  (Oct.  88  UPDATE).  Everything  worked  fine 
until  he  saved  and"~  loaded  back  a  data  file  in 
which  CHR$(10)  happened  to  exist  in  the  115th 
byte  of  a  string  array  element  used  to  store  the 
length  of  first-name  entries.  The  data  became 
corrupted  at  that  point  during  the  save/load 
processes . 

Without  doing  an  extensive  re-write  of  Mail  Pile, 
DATA_F I LE ,  DATA_F I LEQ ,  and  QSO_PILE  which  all  use 
this  kind  of  approach  to  storing  the  lengths  of 
first-entries,  a  quick  and  dirty  fix  Is  to  simply 
change  this  CHR$(10)  to  CHR$(11)  whenever  it 
occurs.  This  will  make  no  difference  when 
fields  one  and  two  are  printed  out  on  separate 
lines,  and  will  add  only  one  extra  space  between 
a  last  name  and  a  first  name  10  characters  in 
length  when  printed  out  on  the  same  line. 

The  following  lines  may  be  inserted  in  theBe 
listings  to  make  this  correction: 

MAIL  PILE: 

825  IP  CODE(f$(n,115))-10  THEN  LET  f $ (n. 1 1 5 )-CHR$ 
(11) 

AODRPILEl: 

695  IF  CODE(f$(n, 179))-10  THEN  LET  f $(n, 179 )-CHR$ 
(11) 

DATA_F I LE  and  DATA_F I LEQ : 

805  IF  CODE(f$(n,cs))-10  THEN  LET  f $(n.cs)-CHR$ 
(11) 

QSO_FILE  and  QSO_FILE2: 

1005  IF  CODE(f$(n,cs))-10  THEN  LET  f $(n,cs)«CHR$ 
(ID 

If  you  have  versions  of  these  or  any  other  of  my 
issue  disk/mdv  programs  that  you  would  like  to 
have  updated,  please  send  return  postage  along 
with  a  copy  of  the  program(s)  on  mdv  or.5XM  DSDD 
disk  compatible  with  TRUMP  CARD. 

(DATA_FILEQ  has  pre-defined  fields  and  labels  for 
use  as  a  logbook  according  to  formal  protocol 
foiiiwd  b;r  mat\7  ham  radio  lasbooKe  ) 


October  1989 


3.9 


Update  Magazine 


Update  Magazine 


October  1989 


PSIOIT  XCHANGE 
Bill  Woodward 

Last  month  I  purchased  the  QL  XCHANGE  from  Sharp's.  For  a  long  time  I  had 
wondered  when  and  if  PSION  XCHANGE  would  be  made  available  to  us  American 
orphan  QL  owners.  It  is  one  of  the  best  $59.95  purchases  I  have  made.  The 
four  PSION  programs  are  tied  together  in  the  XCHANGE  with  the  ability  to 
share  information  between  the  programs  without  going  to  all  the  hassel  of 
changing  mdvs  or  disks  or  importing  and  exporting.  The  more  I  use  XCHANGE 
the  more  user  friendly  features  I  see  and  the  better  I  like  it. 

There  are  several  tutorials  on  the  disk  that  teach  you  ABACUS  &  EASEL.  They 
take  you  one  step  at  a  time  show  you  how  to  proceed.  These  tutorials  are 
loaded  from  Xchange  using  the  command  key  F3;  t  (for  tsl  or  Task  Specific 
Language);  the  file  name,  e.g.,  abacusl_tsl,  abacus2_tsl,  abacus3_tsl, 
easell_tsl,  or  easel2_tsl;  ENTER  and  watch  the  tutorial  unfold.  ABACUSl_tsl 
displays  the  spreadsheet  first  and  proceeds  to  automatically  enter  an 
animation  of  CASH  FLOW  MODELLING  from  page  18-19  of  QLUG.  ABACUS2_tsl  & 
ABACUS3_TSL  displays  the  spreadsheet  and  tutors  a  simple  financial  model 
which  EASELl_tsl  &  EASEL2_tsl  model  on  the  screen. 

Xchange  F3  has  11  commands,  i.e.,  BACKUP, CONTINUE, DELETE, LIST  (dir) , 
NEW, OUTPUT (background  printing),  QUIT,  RENAME,  SET  (default  drives  like 
CONFIG  but  easier  to  use)  TSL,  &  XCHANGE (swaps  data  between  files)  which  are 
accessed  with  F6  and  you  can  return  to  your  present  task  or  a  new  one. 

From  XCHANGE  you  access  superbasic  with  CTRL  C  and  run  I NSTALL_  BAS  and  set 
your  printer  parameters.  I  spent  several  days  setting  up  my  printers.  I  have 
both  serial  and  parallel.  The  printer_dat  is  held  in  xchange  dat.  So  I  set 
up  my  serial  printer  for  continuous  paper  in  xchange  dat.  COPY 
f  lpl_xchange_dat,  f  lpl__  cprinter_dat .  I  then  LRUN  f  lpl__install_bas  and 
changed  continuous  to  no  and  set  up  single  sheet  paper  in  xchangejiat.  I  am 
doing  the  same  for  my  parallel  printer.  The  data  will  be  psprint_dat  and 
pcprint_dat. 

When  writing  letters  I  use  single  sheets  so  in  XCHANGE  I  set  default  to 
FLP2_  while  I  am  writing.  When  I  need  to  print,  I  hit  shift  Fl  to  get  into 
XCHANGE;  F3,  S,  flpl_  to  default  for  printer.  If  I  wish  to  use  any  other 
feed,  I  use  F3,S,raml_  for  default  and  CONTROL,  C  to  get  into  superbasic, 
and  type  COPY  f lpl_cprinter_  dat ,  raml_xchange_dat  if  I  am  using  serial 
printer  with  fanfold  paper  or  COPY  f lpl_psprint_dat , raml_xchange_dat  or 
copy  flpl_  pcprint_dat,  raml_  xchange_dat  for  my  parallel  printer.  All  my 
printer_dat  files  have  the  10  translate  positions  filled,  too,  so  I  can  use 
all  the  features  of  my  printers. 

Xchange  is  like  getting  a  PSION  TOOLKIT  II.  The  HELP  files  are  greatly 
expanded  also,  for  someone  like  me  that  is  blundering  my  way  along  it  is  a 
blessing  to  know  help  is  only  Fl  away. 


PRINTER  INTERFACE 
Bill  Woodward 

Recently  I  acquired  a  Miracle  Systems  CENTRONICS  PRINTER  INTERFACE.  it 
allows  you  to  send  the  serial  output  of  the  QL  to  either  SER1  or  SBR2  and 
run  a  parallel  printer.  You  can  run  a  Dot  Matrix  from  SER2  and  a  daisy  wheel 
printer  from  SBR1.  One  can  be  serial  and  the  other  parallel  or  by  using  two 
Centronics  interfaces  both  can  be  parallel. 


40 

October  1989  Update  htegazine 


Update  Magazine 


October  1989 


ANOTHER  APPROACH  TO  EXTRA  MEMORY  BANKS 

Larry  Crawford,  357  Reyolds  Rd,  London 
Ontario  Canada  N6K  2P8     (519)  657-9119 

Back  in  '86  I  was  faced  with  a 
problem  with  memory.  I  had  a  program  in 
which  I  stored  and  sorted  movie  titles, 
updating  it  each  month.  As  the  list 
approached  1000,  it  was  obvious  that  RAM 
would  soon  be  full  and  extra  banks  of 
memory  were  needed.  I  put  together  a 
board  using  eight  6264  SRAMs  to  give  me 
64K  in  two  banks.  The  following  year  the 
43256  chips  became  available  so.  1 
redesigned  the  circuit  to  give  me  256K 
in  eight  banks.  This  article  will 
describe  how  it  works. 

One  of  the  problems  associated  with 
adding  memory  is  the  necessity  of 
staying  out  of  the  way  of  the  system 
operating  routines.  Memory  is  configured 
into  eight  chunks  of  8K  each  (page  2, 
Tech  Manual).  The  simplest  way  of  of 
avoiding  conflict  is  to  leave  chunks  0 
to  3  in  Home  Bank  enabled  at  all  times 
and  to  enable  only  chunks  4  to  7  of  any 
other  banks  added.  With  an  appropriate 
interface,  Expansion  Banks  can  be  added 
and  controlled  through  the  I/O  ports. 
That  is  the  approach  I  took.  Since  over 
200  ports  are  not  used  by  the  system  or 
other  peripherals,  we  can  add  over  6.4 
MEGAbytes  of  RAM!  Let's  start  less 
abitiously  and  deal  with  ports  0  to  8 
only. 

HOW  IT  WORKS 

When  the  OUT  command  is  used  in 
BASIC,  or  the  OUT  (C),A  instruction  in 
M/C,  the  number  of  the  I/O  port  is  put 
onto  address  lines  AO  to  A7  then  the 
IORQ  and  MR  lines  go  LOW  simultaneously 
(page  12,  Tech  Manual).  When  that 
happens,  two  of  the  three  ENABLE  inputs 
of  the  74138  decoder  are  set  correctly. 
The  third  one  has  yet  to  be  considered. 
Since  the  ports  we  want  to  use  are  0  to 
B,  address  lines  A4  to  A7  will  be  low. 
Consequently  A4,  inverted  by  one  of  the 
NAND  gates  in  Ul,  applies  the  third 
ENABLE  signal  to  the  74138.  Up  to  this 
point,  all  outputs  of  the  decoder  have 
been  HIGH.  Since  lines  A5  to  A7  are  LOW 
and  applied  to  the  three  address  inputs, 
the  output  0  pin  will  go  LOW 
. momentarily. 

41 


This  applies  a  pulse  to  the  Clock 
Pulse  pin  of  the  74374  octal  flip-flop 
which  then  latches  the  outputs  from  . the 
7442  decoder.  While  all  of  this  was 
happening,  address  lines  A0  to  A3 
(carrying  the  port  number  in  binary 
form),  were  decoded  to  a  one-of-ten 
output  by  the  7442.  Only  the  active 
output  goes  LOW:  the  .others  remain  HIGH. 
These  outputs  are  the  ones  latched  by 
the  flip-flop. 

The  eight  outputs  1  to  8  of  the 
flip-flop  are  applied  to  eight  inputs  of 
two  7432  OR  gates.  It  is  at  this  stage 
that  the  final  address  decoding  is  done. 
Address  line  A15  is  applied  to  the  other 
inputs  of  the  OR  gates  through  an 
inverter.  Since  the  extra  Banks  are 
located  in  the  upper  32K  of  memory,  A15 
will  be  HIGH  when  they  are  active.  Thus 
only  when  one  of  the  flip-flop  outputs 
is  LOW  AND  A15  is  high  will  one  of  the 
OR  gate  outputs  be  LOW.  These  outputs 
are  connected  to  the  respective  ENABLE 
(LOW  active)  pins  of  the  DRAMs. 

A  very  useful  "frill"  is  the 
inclusion  of  8  LEDs  to  indicate  which 
bank  is  active.  Should  any  bank  except 
the  Home  bank  be  active,  all  sorts  of 
strange  things  can  happen  unexpectedly. 
For  instance,  it  is  not  possible  to  LOAD 
or  SAVE  when  another  bank  is  active.  It 
is  also  very  useful  to  know  exactly 
which  bank  is  being  used  by  your 
routines  and  to  know  whether  or  not 
things  are  going  along  as  you  had 
planned. 

Another  option  is  the  provision  of  a 
battery  backup  to  provide  non-volitile 
memory.  The  data  in  the  bank  will  be 
held  even  after  the  computer  is  switched 
off.  The  four  inputs  of  the  Ul  NAND  gate 
that  are  tied  together  are  connected  to 
the  computer's  5V  supply  through  an  RC 
circuit  which  will  prevent  the  output  of 
the  gates  from  going  LOW  for  about  a 
third  of  a  second,  thus  allowing  the 
power  supply  a  little  time  to  settle 
down.  This  resistor  and  capacitor  and 
the  eight  pullup  resistors  connected  to 
pin  20  of  the-  memory  chips  would  not 
needed  if  battery  backup  is  not  wanted. 

BANK  SWITCHING 

Port  F4  (244  decimal)  contains  the 
Horizontal    Select    Register    (page  37, 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


Tech  Manual).  The  8  bits  in  this 
register  determine  if  the  respective 
chunks  of  the  Home  bank  are  active.  Thus 
to  "make  room"  for  another  bank  in 
chunks  4  to  7,  we  must  turn  off  these 
chunks  by  changing  the  Register  to 
11110000  binary  (240  decimal  or  F0  hex). 
The  command  OUT  244,240  or  the  M/C 
instructions  <LD  A,F0>  <OUT  (F4),A>  will 
do  the  job.  Now,  to  activate  bank  n,  the 
command  OUT  n,0  is  used.  Where  n  is  an 
integer  from  1  to  8.  The  0  in  this 
command  can,  in  fact,  be  any  number 
because  the  data  it  represents  is  not 
decoded  by  the  interface.  Some  value 
must  be  given  to  satisfy  the  System 
logic.  To  return  to  normal  Home  bank 
operation,  use  OUT  0,0  :  OUT  244,0.  Bank 

0  is  the  Home  bank  since  output  0  of  the 
7442  decoder  is  not  connected  to  any  of 
the  SRAMs. 

CONSTRUCTION 

After  several  frustrating  attempts 
at  etching  a  board  using  a  photo  resist, 

1  decided  to  go  the  hand-wiring  route. 

Use  a  4"m4"  piece  of  perfboard  with 
0.1"  centered  holes  and  a  strip  of  old 
circuit  board  with  double  sided  edge 
connector  fingers  glued  to  one  edge. 
Mine  came  from  a  board  in  a  surplus 
store.  If  you  have  to  make  your  own,  it 
is  prudent  to  tin  plate  the  copper 
fingers  to  head  off  oxidation  problems 
later.  The  Liquid  Tin  to  do  this  is 
available  from  large  suppliers  such  as 
Active  Components. 

Mount  the  sockets  by  feeding  their 
legs  through  the  perfboard  holes  and 
bending  them  flat  against  the  board  on 
the  other  side.  Use  wire-wrap  wire  to  go 
from  point  to  point,  starting  with  one 
of  the  edge  connectors.  It  goes 
surprisingly  quickly  since  it  is 
possible  to  melt  through  the  insulation 
on  the  wire  to  make  a  connection  without 
having  to  cut  and  strip  the  ends.  The 
multitude  of  wires  running  between  the 
RAMs  on  the  left  and  right  halves  of  the 
board  can  be  threaded  through  holes  and 
cross  over  on  the  top  side,  thus  getting 
them  out  of  the  way.  Check  all  lines 
with  an  ohmmeter  before  plugging  in  the 
ICs.  After  protecting  the  edge 
connectors  with  masking  tape,  spray  the 
back  of  the  board  with  clear  lacquer  to 
hold  the  wires  in  place.  The  whole 
project  took  about  10  hours  and  plugs 
into  an  Oliger  expansion  board. 

CcnT    M^T  PA^C 
October  1989 


PUBLIC  DOMAIN  LIBRARIES 

And  some  new  Ideas 

The  CATS  TSUG  advises  that  their  library  for 
the  TS-2068  is  on  Cassette  only.  Three  tapes  are 
available  with  over  140  programs  total.  All  three 
for  $9.00  or  $3.00  each.  Be  nice  and  send  an 
extra  buck  for  postage.  Joe  Miller  CATS,  1704 
Dayton  St.,  Hyattsville,  MD  20703. 

ALL  SYSTEMS  LIBRARY:  The  Ontario,  Canada 
TSUG  has  a  broad  Public  Domain  Sinclair  Library, 
too  diversified  to  list  in  detail.  Covered  are 
Cassette  for  the  TS-2068,  an  extensive  LARKEN  DISK 
Library,  and  now  a  Sinclair  QL  library  is  being 
established.  For  details  send  SASE  with  two  US 
Dollar  bills  for  information.  Save  your  US  Stamp 
as  Canadian  Post  needs  their  own  revenue  for 
postage.  And  dont  send  US  coin  or  stamps. 
Returned  will  be  a  listing  of  their  library  and 
low  prices.  Its  worth  your  buck.  George 
Chambers,  14  Richome  Court,  Scarborough,  Ontario 
M1K  1Y1,  Canada. 

SINCUS  LIBRARY:  TS-2068  Library  on  Cassette, 
Oliger  Disk,  or  LKDOS  DISK.  Send  $2.00  for 
information  package  to:  John  Colona  SINCUS,  28 
Guilfoyle  Ave.,  Binghampton,  NY  13903. 

VISTA  LIBRARY:  TS-1000  and  TS-2068  on 
Cassette,  and  TS-1000  and  TS-2068  on  LKDOS  DISK. 
Send  $2.00  for  information  package  to:  Tony 
Hilling  VISTA,  Box  199,  Vashon,  HA  98070. 

ISTUG  LIBRARY:  TS-1000  and  TS-2068  Library 
on  Cassette  and  Oliger  Disk.  Send  $2.00  to: 
Frank  Davis  ISTUG,  513  East  Main,  Peru,  IN  46970 
or  call  (317  473-8031) 

NOTICE  TO  TSUGS:  Those  TSUGS  not  mentioned 
above  that  desire  public  announcement  of  their 
services  or  programs  are  offerred  space  in  Update 
free  for  such  announcements. 


Update  has  most  of  the  above  listed 
libraries.  They  came  by  the  bag  at  ridiculuous 
low  prices,  something  like  5  cents  or  less  per 
program.  There  are  enough  good  and  useful 
programs  in  every  disk  or  cassette  to  be  worth 
five  times  the  TSUG  price  for  the  library.  Each 
library  will  have  some  overlaps  but  each  will  have 
programs  that  the  others  do  not  have.  These  are 
put  together  with  a  lot  of  volenteer  long  hours 

42 

Update  Magazine 


Editorial  Review  of  Public  Domain  Libraries 


LED5 


ACTIVE  DANK 
1     2,   J   4-    5*  t 
►O    O    O    O   O  O 


7  8 


U4 
»V4 


U3 
'42. 


U2 
'158 


Bank 
1 

43X5*  SRAM 


7  . 


BOAfc»  WITH  CP<,E    PlH«»ft.«    «LUB>  TO  PCRF&o,«,*.t> 


37 


25-fcK 


EXPANSION  RANKS  CoHPONBNT  LAYOUT  .V 


contributed  freely,  thus  the  TSUG  can  be  generous, 
and  thus  the  low  prices. 

Generally,  public  domain  software  are 
programs  and  utilities  created  by  individual 
programmers  who  donated  their  work  to  all.  Some 
are  lacking  in  application  while  others  are  quite 
extensive.  About  30%  are  games.  For  even  the 
lessor  programs  there  are  interesting  programming 
techniques  to  be  studied  and  used.  The  libraries 
on  disk  generally  go  beyond  this  scope  and  provide 
exceptionally  useful  disk  management  tool  kits, 
and  have  programs  that  were  designed  for  cassette 
opertation  and  then  modified  and  expanded  for  disk 
operation.  An  example  of  this  is  the  LKDOS 
Library  by  the  Ontario  TSUG  which  has  an 
invaluable  group  of  LKDOS  Disk  Management 
programs. 

The  Sinclair  QL  is  lacking  in  Public  Domain 
programs  available  in  North  America.  One  group, 
the  Ontario  TSUG  is  working  hard  to  produce  a  QL 
PD  Library.  HELP  is  needed  from  programmers  who 
are  willing  to  donate  useful  utilities  to  Public 
Domain..  Send  your  programs  on  disk  or  mdv  to: 
Hugh  Howie,  Sine  Link,  586  Oneida  Drive, 
Burlington,   Ontario  L7T  3V3,   CANADA.   Even  the 


most  insignificant  of  utilities  will  be 
appreciated.  If  it  does  a  job  for  you  it  will  be 
useful    Ko    others.     CREDITS  will  be  oiven  to  the 


author. 


Suggestions  to  TSDGS 


While  on  '  the  subject  of  TSUGS  and  PUBLIC 
DOMAIN  Libraries,  I  have  the  feeling  that  there  is 
a  need  for  an  intermediate  library  effort  of  sorts 
in  the  TSUG  programs.  How  about  a  "SHAREWARE 
LIBRARY"  for  both  TS-2068  and  Sinclair  QL?  Many 
programmers  have  become  dormant  because  of  the  low 
level  of  buying  activity  in  the  Sinclar  user 
group.  This  is  of  course  because  of  our  low 
numbers.  A  TSUG  Librarian  could  rummage  through 
past  magazine  issues  and  find  dozens  of 
programmers  and  small  software  businesses  that  are 
no  longer  active. 

I'll  bet  that  letters  to  these  non-active 
programmers  can  result  in  many  of  their  excellent 
programs  being  assembled  into  a  "SHAREWARE 
LIBRARY"  that  would  be  even  more  useful  than  our 
public  domain  libraries.  Of  course,  the  librarian 
would  have  to  craft  a  "SHAREWARE  NOTICE"  for  every 
single  program  so  that  the  Author  would  have  some 
chance  of  remuneration  from  honest  users.  My 
visualization  of  how  this  would  work  is:  A  TSUG 

43 


October  1989 


Update  Magazine 


Update  Magazine 


October  1989 


o 


I*  3  <»  <r  3  |w 


<<•<<<<<< 


1 01  h-v9  lr>  ** 
lO  Q  O  o  o  O 


<  <  Q  O  O 


Z 

o 
ui 

X 
Hi 

O 
UJ 


CO 

o 
h 


h 
0 

"  < 
itf  3  p 

CD 


#»*  *S  8<  51  *nt 


3  ft»sj(  >-  s*m~ 


*1 


!iJ2 

<<ttti 


<3 


iff  HI!  ! 


<3  0 

>   £  l\J     |fk  «*• 

o   o.   o   o   S  a 


00 

3 

3 

m 

vS 

9 

— j 

^  ^  in  \|-  'ln  vj  h  oo 

?  3  q    m  H  ^  J 
<   <  <  <  & 


^  »i  «\i  ro 
<   <   <  < 


4* 


CM  3 

<  <  N 


v  }  ^ 

K  Ifl 
<    <  < 

44 


October  1989 


Update  Magazine 


Update  Magazine   ,   a  October  1989 

''/J 

WINDOW  DEFINING: 
A  Program,  part  II 

by  David  McCall 

In  the  last  article,  we  wrote  the  assembly  language  routine  which  will  become 
part  of  our  window  defining  program.  In  this  article  we  will  write  and  discuss  the 
different  functions  that  will  be  used.  SuperBASIC  gives  us  the  ability  to  write 
very  versatile,  many  variable  functions  which  can  do  more  than  merely  return  a 
number.  Next  time  the  procedures  will  be  discussed.  Once  completed,  the  program 
will  provide  all  the  information  discussed  below  and  more  in  a  user  friendly  pop 
up  window.  The  window  being  defined  will  be  able  to  be  positioned  and  sized  on  the 
screen  without  overwriting  anything,  such  as  other  windows  or  text.  Every 
attribute  about  a  window  will  be   defined  and   a  sample   window  displayed   on  the 

SCre<The  following  SuperBASIC  programs,  functions  and  procedures  have  been  written 
in  a  very  structured  style.  This  is  very  helpful  when  trying  to  follow  the  logic. 
Different  techniques  are  used  to  demonstrate  the  power  and  adaptability  ot 
SuperBASIC.  From  looking  at  the  listing,  the  use  of  indentation  is  quite 
prominent.  This  is  another  helpful  technique  when  trying  to  read  long  programs 
because  the  nested  control  is  very  clearly  marked  by  the  appropriate  indentation. 

The  description  begins  with  the  simple  sign  function,  sgnX.  It  will  return 
the  sign  of  a  number:  1  if  positive;  -1  if  negative;  and  0  if  zero.  As  indicated 
by  the  percentage  symbol  affixed  to  the  end  of  the  name,  the  function  is  of 
integer  type.  The  logic  will  be  a  one  lined  IF-THEN -ELSE  statement,  lines  2000  to 
2020.  First  the  number  needs  to  be  tested  against  zero  and  a  zero  returned  if  so. 
Otherwise,  the  sign  which  is  the  absolute  value  of  the  number  divided  by  itselt  is 
returned,.^  ^  RETurn  was  used.    It  is  important  to  remember  that 

once  a  RETurn  has  been  encountered  execution  leaves  the  function  or  procedure  at 
that  point.  Also,  the  name  of  the  function  is  included  in  the  END  DEFine  statement 
making  it  and  other  functions  easier  to  identify. 

The  minimum  of  two  numbers  is  another  function  which  is  useful.  The  logic  is 
eiven  in  lines  2280  to  2340.  The  function  name  is  Min  and  takes  two  parameters, 
inl  and  mn2.  As  indicated  by  the  function  and  parameters  names,  it  is  and  takes 
real  or  floating  point  numbers.  The  long  form  of  the  IF-THEN-ELSE  statement  is 
used  this  time.  Note  that  this  function  can  be  used  to  determine  the  minimum  ot 
more  than  two  numbers.  For  example,  the  minimum,  x,  of  three  numbers,  rail,  rat*, 
rai3,  can  be  determined  by  the  following  statement: 

x  -  Min(  iml,  Min(  rai2,  rai3)) 

All    functions  and  procedures  can  be  called  recursively,  like  above,  or  within  the 
function  or  procedure  itself. 

The  next  group  of  functions  are  all  real  valued  but  take  no  parameters. 
Instead  global  variables  are  used  to  pass  parameters,  for  several  reasons.  First, 
the  variables  are  constantly  being  changed  and  second,  the  functions  never  require 
different  parameters.  Additionally,  it  shows  another  alternative  for  the  use  of 
functions.  They,  max  xp,  max_yp,  max  xpix,  max  ypix,  max_xc,  and  maxyx,  determine 
the  maximum  x  and  y  point,  pixel,  and  character  positions  for  a  window, 
respectively.  Keep  in  mind  that  a  pixel  is  the  smallest  screen  element  the 
computer  can  access,  while  a  point  is  a  position  mapped  onto  these  pixels.  To 
clarify  this  concept,  remember  that  the  absolute  maximum  number  of  pixels  across 
the  screen  is  512  while  the  number  of  points  can  be  any  value  depending  upon  the 
scaling. 

The  global  variables  used  are: 

scl  -  the  SCALE  of  the  window 
■  xg,yg  -  the  graphics  origin  defined  by  the  SCALE  command 
scr_x  -  the  x  dimension  of  the  window 
scry  -  the  y  dimension  of  the  window 
order  -  the  BORDER  width  .      .  . 

cxi,cyi  -  the  ISumber*  of  pixels  a  character  occupies  in  the  x 
and  y  directions 

The  simolest  functions  is  maxyp,  lines  2040  to  2060.  The  number  of  points  in 
the  y  dirSn!  sc"  is  defined  ~w!th  theSCALE  command.  The  nuximum  y  position 
is,  therefore,  the  y  origin  value,  yg,  added  to  scl. 

The  most  difficult  to  understand  function  is  max_xp,  lines  2080  to  2100.  it 
is  a  function  of  many  variables  xg,  scl,  order  scr  x,  and  scry,  and  the  compu- 
tation is  complex.    TheSCALE    command  scales    the  window   by  making    the  x    and  y 

October  1989  45  Update  Magazine 


Update  Magazine 


October  1989 


experimentally  to  give  the  best  answer  in  the  function).  The  number  of  pixels  that 
are  accessible  in  the  window  are  not  scrjx  and  scr_y  if  a  border  is  defined.  They 
are  (scrjy  -  2  *  brder)  and  (scr_x  -  4  *  brder)  —  the  BORDER  width  is  doubled  in 
the  y-direction  and  quadrupled  in  the  x-direction. 

To  calculate  the  maximum  point  position  in  the  x-direction,  the  maximum 
length  of  the  window  in  the  y-direction  must  be  mapped  into  length  as  measured  in 
the  x  direction.  This  is  done  by  multiplying  scl  by  (503/802).  This  result  must 
then  be  multiplied  by  the  ratio  of  pixels  in  the  different  direction,  (scr_x  - 
4*brder)/(scri_y  -  2*brder).  Finally,  it  must  be  added  to  the  x  value  of  the 
graphics  origin,  xg. 

The  expression  for  this  calculation  given  in  line  2090  has  alternating 
division  and  multiplication  to  maintain  as  many  significant  digits  as  possible. 
Whenever  a  calculation  requires  many  multiplications  and  divisions,  it  should 
always  be  arranged  such  that  the  two  operations  alternate  with  division  coming 
first.  Otherwise  more  significant  digits  can  be  lost  by  the  rounding  error  in  the 
computer. 

As  discussed  above,  the  number  of  accessible  pixels  in  the  defined  window  is 
(scry  -  2  *  brder)  and  (scr_x  -  4  *  brder).  To  obtain  the  values  for  max  xpix  and 
max_ypix,  one  must  be  subtracted  from  both,  see  lines  2120  to  2180.  This  makes 
the  pixel  origin  (0,0)  instead  of  (1,1).  ( 

The  last  window  characteristic  functions,  max_xc  and  max_yc,  are  relatively 
simple.  These  determine  the  maximum  number  of  characters  that  can  be  printed  in 
the  window  with  the  specified  character  size.  This  calculation  is  the  integer 
portion  of  the  maximum  pixels  divided  by  the  number  of  pixels  the  character  takes 
up.  For  the  x  and  y  directions,  the  equations  are  INT((scr  x  -4*brder  -1)/  cxi) 
and  INT((scr  y  -2*brder  -1)/  cyi),  respectively.  Please  refer  to  lines  2200  to 
2260.  •  f 

Finally,  the  remaining  functions  are  used  in  conjunction  to  replace  the 
standard  INPUT.  In  their  present  state,  they  allow  only  integer  values  with  a 
specified  number  of  digits  and  maximum  value.  The  values  inputted  with  these 
routines  are  constantly  right  justified  as  they  are  typed  in  and  if  nothing  is 
entered,  a  default  value  is  returned.  Also,  if  positive  numbers  are  only  desired, 
they  will  ensure  this.  . 

The  function  get_nura!  calls  the  main  function  routine,  input!,  which  handles 
all  justification  and  keyboard  reading.  Get_nimZ  performs  the  limit  and  sign 
testing  and  returns  the  proper  value  according  to  the  restrictions  given.  The 
first  line,  2380,  calls  input!  and  sets  the  return  value,  old!,  to  a  default  value 
if  nothing  has  been  entered.  The  next  line,  2390.  checks  to  see  if  the  value  is 
greater  than  the  maximum  value,  max!.  If  greater,  it  sets  the  return  value  to  the 
maximum  value.  The  following  line,  2400,  checks  the  positive  value  only  flag, 
positive!,  and  if  set,  makes  sure  the  value  is  positive.  Finally,  line  2410 
returns  the  value. 

The  last  function,  inputX,  lines  2440  to  3420,  will  not  be  discussed  line  by 
line  as  the  previous  ones  were  because  of  its  length.  However,  each  major  section 
will  be  discussed  and  explained.  The  first  five  lines  initialize  the  variables, 
set  ink  color,  and  define  the  local  variables.  The  rest  of  the  function  is  a 
REPeat  loop  with  a  large  SELect  ON  statement  nested  inside.  Basically  the  function 
constantly  checks  the  keyboard  with  an  INKEY$  function  and  the  SELect  ON  statement 
performs  the  necessary  tasks  depending  upon  '  the  key  enteredT^inUHiber  being 
entered  is  kept  in  a  string  stg$.  The  variable  posZ  keeps  track  of  the  string 
position  the  cursor  is  presently  in,  length!  holds  the  number  of  digits  typed,  and 
max!  is  the  maximum  number  of  digits  allowed. 

The  first  few  lines  of  the  REPeat  loop,  2520  to  2560,  print  the  cursor  and 
retrieve  the  next  key.  The  SELect  statement  processes  the  key  typed.  If  the  "ESC" 
key  is  typed,  the  program  is  stopped,  lines  2580  to  2590.  If  "-"  or  "_"  is  typed  a 
negative  sign  is  inserted  at  the  far  left  position,  2600  to  2610.  Similarly,  if 
"-"  or  "+"  is  typed,  a  .  space  is  put  in  the  far  left  position.  If  a  number  is 
typed,  it  is  inserted  at  the  present  cursor  location  and  the  number  of  digits, 
length!,  is  increased,  2640  to  2780.  As  you  can  see,  a  double  nested  IF-THEN-ELSE 
statement  is  used.  This  is  necessary  because  of  the  different  cursor  positions, 
far  left,  far  right,  in  the  middle,  that  are  possible  and  the  string  functions  in 
SuperBASIC  require  different  handling  in  each  case. 

Lines  2790  to  2850  move  the  cursor  about  the  already  typed  numbers  and  it  is 
not  allowed  to  move  across  any  untyped  space.  Right  deletion  is  handled  With  lines 
2860  to  3050.  Again  there  are  two  nested  IF-THEN-ELSE  structures  taking  care  of 
the  different  possibilities  that  could  arise.  The  outer  IF  statement  checks  to  see 
where  the  cursor  is  in  the  string.  If  it  is  at  the  first  position,  removing  a 
character  is  easier.  However  if  there  has  only  been  one  character  typed  in  the 
string  can  be  reset  to  its  initial  state  otherwise  the  rest  of  the  characters  need 
to  be  shifted. 

October  1989  4  6  update  iAag&zine 


Update  Magazine 


October  1989 


When  the  cursor  is  not  in  the  first  position,  the  string  needs  to  be  cut  in 
two  and  put  back  together  without  the  deleted  character.  The  left*  and  right! 
variables  are  used  to  find  the  position  just  left  of  the  cursor  and  just  right  of 
the  cursor.  The  string  is  then  reconstructed  after  the  left  position  is  checked  to 
make  sure  it  is  still  within  the  string. 

Left  deletion  is  performed  by  lines  3060  to  3260  and  is  analogous  to  the 
right  delete  except  it  does  not  remove  the  character  the  cursor  is  on  like  the 
regular  INPUT.  The  right  delete  was  chosen  to  perform  this  action  because  the 
routine  keeps  numbers  right  justified.  .  ■     ••  . 

The  number  is  entered  whenever  "Return",  "Up  Arrow",  or  'Down  Arrow  is 
pressed,  lines  3270  to  3300.  The  last  ON  clause  repeats  the  loop  again  if  any 
other  key  is  typed.  Immediately  following  the  END  SELect,,  lines  3340  to  3350,  are 
the  lines  which  update  the  string  on  the  screen.  Finally,  lines  3370  to  3410 
return  the  value  entered  or  -9999,  which  indicates  nothing  has  been  typed  in. 

Half  of  the  larger  window  defining  program  has  been  covered  with  this  second 
article.  You  will  notice  that  the  line  numbering  started  at  2000.  Each  article  has 
been  constructed  to  ensure  no  line  numbering  conflicts  when  they  are  all  merged 
together  at  the  end  of  this  series.  The  complete  program  will  be  available  on  an 
"Issue  Disk"  also. 


LISTING  A 

2000  DEFine  FuNction  sgn%(t%) 

2010       IF  t%«0  THEN  RETurn  0:ELSE  RETurn  ABS(t%)/t% 
2020  END  DEFine  sgn% 
2030  : 

2040  DEFine  FuNction  max_yp 
2050       RETurn  scl  +  yg 
2060  END  DEFine  max_yp 
2070  : 

2080  DEFine  FuNction  max  xp 

2090       RETurn  scl/802*5U3/(scr_-y-2*brder-l)*(scr_x-4*brder-l)+xg 
2100  END  DEFine  max_xp 
2110  : 

2120  DEFine  FuNction  max  xpix 
2130      RETurn  (scr_x-4*Erder-l) 
2140  END  DEFine  max_j>ix 
2150  : 

2160  DEFine  FuNction  max  ypix 
2170      RETurn  (scr_y-2*brder-l) 
2180  END  DEFine  max_ypix 
2190  : 

2200  DEFine  FuNction  max_xc 

2210      RETurn  INT((scr_y-2*brder-l)/cyi) 

2220  END  DEFine  max_xc 

2230  : 

2240  DEFine  FuNction  max_jc 

2250      RETurn  lNT((scr_x-4*brder-l)/cxi) 

2260  END  DEFine  max_yc 

2270  : 

2280  DEFine  FuNction  Min(mnl,mn2) 

2290       IF  mnl<mn2  THEN 

2300  RETurn  mnl 

2310  ELSE 

2320  RETurn  mn2 

2330       END  IF 

2340  END  DEFine  Min 

2350  : 

2360  DEFine  FuNction  get_num%(win%,x,y,len%,old7.,max%,positve%) 
2370  LOCal  t% 

2380       t%-input7o(win%,x,y,len%):IF  t%<>-9999  THEN  old%-t% 
2390       IF  ABS(old%)>max%  THEN  old%-sgn%(old%)*max% 
2400      IF  positve%  THEN  old7.-ABS(old%) 
2410      RETurn  old% 
2420  END  DEFine  get_num7. 
2430  : 

2440  DEFine  FuNction  input%  (win%,x,y,max%) 

2450  LOCal  loop7.,k$(l) ,k,s$(l) ,stg$(max%) ,pos%,right%, lef t7., length% 
2460  INK#win7.,7 
.     2470     s$(l)-'  1  . 
October  1989  H  /  M^azine 


Update  Magazine 


October  1989 


2480  stg$«FILL$( '_'  ,max%) 

2490  pos%«l 

2500  length%»0 

2510  REPeat  loop7. 

2520  0VER#win%,  -1 

2530  AT  #win%,x,y-hnax%-pos%:  PRINT  #win%, '  ' 

2540  OVER  #win%,0 

2550  k$(l)-INKEY$(#3) 

2560  k«G0DE(k$(l)) 

2570  SELect  ON  k 

2580  ON  k-27 

2590  STOP 

2600  ON  k-45,95 

2610  s$(l)-,-, 

2620  ON  k-43,61 

2630  s$(l)»'  ' 

2640  ON  k-48  TO  57 

2650  IF  pos%-l  THEN 

2660  IF  max%>l  THEN 

2670  stg$(l  TO  max%)-stg$(2  TO  max%)&k$(l) 

2680  ELSE 

2690  stg$(l)-k$(l) 

2700  END  IF 

2710  ELSE 

2720  IF  pos%<max7o  THEN 

2730  stg$(l  TO  max%)-stg$(2  TO  max%-pos%+l)&k$(l)& 

stg$(max%-pos%+2  TO  max%) 

2740  ELSE 

2750  stg$(l  TO  max%)«k$(l)&stg$(2  TO  max7.) 

2760  END  IF 

2770  END  IF 

2780  length%-(length%+l):IF  length%>max%  THEN  Iength7.«max7. 

2790  ON  k-200 

2800  pos%  -  pos%  -1 

2810  IF  pos%<-0  THEN  pos%  -  1 

2820  ON  k-192 

2830  pos%  -  pos%  +1 

2840  IF  pos%>-Iength7.   THEN  pos%  -  length7. 

2850  IF  pos7.-0  THEN  pos7.-l 

2860  ON  k-202 

2870  IF  pos7.  <>  1  THEN 

2880  left7.  -  max%-pos% 

2890  right7.  -  max%-pos%+2 

2900  IF  left7.  <  1  THEN 

2910  stg$(l  TO  max7.)-*_'&stg$(2  TO  max7.) 

2920  ELSE 

2930  stg$(l  TO  max7.)-'_,&stg$(l  TO  lef  t7.)&stg$(right%  TO  max%) 

2940  END  IF 

2950  Iength7.-Iength7,-1:IF  length7.<0  THEN  length7.-0 

2%0  ELSE 

2970  IF  max7.-l  THEN 

2980  stg$(l  TO  max7.)-'_* 

2990  ELSE 

3000  stg$(l  TO  max7.)-'_,&stg$(l  TO  max7.-l) 

3010  END  IF 

3020  Iength7.-Iength7.-1:IF  length7.<0  THEN  length7.-0 

3030  END  IF 

3040  pos%-pos%-l 

3050  IF  pos%<-0  THEN  pos7.-l 

3060  ON  k-194 

3070  IF  pos7.  -  1  THEN 

3080  IF  max7.<-2  THEN 

3090  IF  max7.=2  THEN 

3100  stg$(l  TO  max%)-,_'&stg$(max%) 

3110  Iength7.-Iength7.-1:IF  lengtl\%<l  THEN  length%-l 

3120  END  IF 

3130  ELSE 

3140  stg$(l  TO  max7.)-'_'&stg$(l  TO  max7.-2)&stg$(max7.) 

3150  length%-length7.-l:IF  length%<l  THEN  length%-l 

3160  END  IF 

3170  ELSE 

i,  0  Update  Magazine 


Update  Magazine 


October  1989 


3190  righa-maxZ-posZ+1 

3200  IF  lef  t7.<l  THEN 

3210  stg$(l  TO  max%)-'_'4stg|(righa  TO  max!) 

3220  ELSE 

3230  8tg|(l  TO  roaxX)-'  'ABtgld  TO  lef  tX)&atg$(rightZ  TO  roaxX) 

3240  END  IF 

3250  lengthZ-leiigthZ-l:lF  lengthJKO  IUEN  lengthX-0 

3260  END  IF 

3270  ON  k-10,208,216 

3280  AT#winZ,x,y-l 

3290  PRINT  #win%,8$(l)&stg$ 

3300  EXIT  loop* 

3310  ON  k-  REMAINDER 

3320  NEXT  loopZ 

3330  END  SELect 

3340  AT#winX,x,y-l 

3350  PRINT#winZ,8$(l);atg$ 

3360  END  REPeat  loopZ 

3370  IF  lengthZ-0  THEN 

3380  RETurn  -9999 

3390  ELSE 

3400  RETurn  a$(l)&atg|(maxZ-lengthX+l  TO  max*) 

3410  END  IF 

3420  END  DEFine  input! 


Librarian  would  spend  some  of  the  clubs  rich 
finances  to  write  to  the  programmers  and  defunct 
software  businesses,  explaining  the  objectives  and 
promising  that  a  Shareware  Notice  would  be 
attached  to  any  program  donated  to  the  library. 

The  Shareware  Library  would  be  assembled  and 
sold  for  a  small  fee  to  re-pay  the  TSUG  treasury 
and  perhaps  make  a  nominal  profit.  Here  we  would 
have  a  level  of  professionalism  in  the  Shareware 
Library  that  exceeds  that  of  a  public  domain 
library.  Most  honest  users  woud  respond  to  the 
Shareware  notice  and  send  the  author  his  just 
deservings  for  the  use  of  the  program.  An 
organized  effort  to  serve  the  users  with  good 
programs  could  just  entice  some  of  our  dormant 
programmers  to  begin  producing  again.  A  TSUG 
could  set  its  own  standards  for  "Read  Me"  doc 
files  to  enhance  the  value  of  the  library.  Some 
work  in  that  area  would  justify  the  small  profits 
to  be  realized  by  the  Club  treasury. 

There  is  no  reason  why  our  active  dealers 
shouldn't  pick  up  upon  this  idea  and  develop  their 
own  Shareware  Libraries.  Generally  Shareware 
Software  is  fully  documented  within  the 
programming  by  "Read  MeM  files,  and  is  not 
supported  by  paper  manuals.  Thus  the  distribution 
of  Shareware  programs  is  simply  one  of  supplying 
the  programs  on  a  medium.  And,  the  distributor 
carries  no  responsibility  for  adequacy  of  either 
the  programs  or  their  documentation.  The  success 
of  the  Author  in  receiving  payment  for  his  work 
depends  upon  his  prowess  in  explaining  his  program 
in  the  Read-Me  files. 


If  the  (honest)  user  finds  the  program  to  be 
useful ,  then  his  conscience  works  on  him  to  send 
the  Author  what  the  user  feels  that  the  program  is 
worth.  Here-to-fore  the  Shareware  concept  has  not 
been  very  successful.  This  is  because  it  has  been 
a  singular  effort  by  single  progammers  who  have 
had  difficulty  in  letting  the  public  know  about 
their  product  availibility.  A  combined  disk  with 
several  author's  programs,  distributed  by  a  TSUG 
or  Dealer,  could  be  of  benefit  to  all.  Update 
Magazine  will  help  to  publicise  such  an  effort  by 
the  TSUGS  and  our  Dealers. 


other  with  30  Mgbt  Hard  drive  and  operating  MS 
DOS.  Each  has  two  MDV's  making  seven  storage 
devices  at  disposal.  Anybody  want  to  tackle  an 
algorithm  for  that  scheme? 

TS-2068  to  QL  LINK  SOFTWARE?  Why  not?  This 
is  so  close  to  reality  that  it  should  be  done. 
What  we  need  is  an  adaptation  of  Modem  Software 
that  operates  direct  from  the  TS-2068 *s  ZSI/O  to 
the  QL's  Serial  I/O  port.  Another  Idea  is  to  use 
two  modems  hooked  together,  and  their  software, 
without  going  through  the  telephone  medium.  There 
are  people  doing  this,  but  how  they  do  it  is  not 
known  publically. 

I  have  pile  of  good  stuff  for  the  "Perks  and 
Quirks"  column  for  next  issue.  There  just  wasn't 
room  for  more  in  this  one.  John  Juergens  accused 
me  of  being  "anti  Micro  Drive",  which  deserves  a 
smart  answer,  plus  more  good  and  better  stuff. 
Incidentally,  I  use  the  PSION  suite  right  out  of 
micro  drive  almost  all  of  the  time.  I  have  an 
idea  for  a  "QL  Hard  Floppy"  for  the  next  issue 
which  I'll  get  our  QL  Editor  to  authenticate. 


October  1989 


Update  Magazine 


The  UPDATE  Computer  Desk 


Several  have  ask  about  how  things  are  set  up 
at  the  UPDATE  Computer  room.  So,  we  will  use  a 
couple  of  pages  to  d I  scribe  the  lash  up.  The 
sketch  on  the  facing  page  gives  a  busy  diagram  of 
the  three  computer  and  two  printer  system.  Not 
shown  Is  the  ml r I  ad  of  power  and  Interface 
cabling.  The  whole  system  Is  set  up  on  a  "door 
blank",  purchased  from  a  lumber  yard,  varnished  to 
a  nice  finish.  This  desk  top  sits  upon  three 
cabinets  that  have  shelves.  These  teakwood 
cabinets  have  ornate  picture  carvings  and  were 
sent  home  from  Thailand  during  the  Viet  Nam  war. 
So    the    entire  computer  desk  Is  quite  attractive. 

When  such  a  system  Is  first  Installed  the 
biggest  problem  Is  to  avoid  getting  caught  In  the 
spider  web  of  cabling.  This  requires  some 
planning.  Four  6  outlet  receptacle  boxes  are 
used.  Two  of  them  have  both  voltage  spike  and  RFI 
protection.  The  equipment  was  first  placed  into 
position  and  then  the  cabling  was  run  to  the  rear 
of  the  desk  and  lashed  up  Into  trunk  lines,  the 
surplus  lengths  folded  back  and  tied.  All  of  the 
equipment  was  purchased  from  our  own  Sinclair 
Suppliers  over  a  period  of  time,  which  avoided 
difficulty  with  cables  and  connectors  not 
matching. 

THE  DISK  CABINETS:  One  for  the  QL  has  2  80 
track  drives.  One  for  the  TS-2068  has  three  80 
track  drives  and  a  40  track.  Another  for  the 
TS-2068  has  two  40  track  drives,  it  Is  common 
practice  to  change  drive  unit  Data  Cables  while 
power  Is  on  In  order  to  copy  disks  of  different 
mixtures,  80  to  80,  40  to  40,  or  80  to  40.  This 
Is  quite  safe  with  Shughurt  DOS  systems.  Both 
monitors  sit  upon  stands  that  allow  equipment  to 
be  positioned  underneath.  Under  the  QL  Monitor  is 
the  Coleco  Adam  Power  supply  and  an  A/C  receptacle 
unit.  Beneath    the   TS-2068    monitor    Is  the 

extension  to  the  1/0  bus,  the  A/B  switches,  and 
the  Printer  Buffer. 

The  QL  System  has  Trump  Card,  EPROM  for  ROM 
change,  and  Speed  Screen  In  ROM.  A  spare  QL  has 
different  tool  kits  than  the  main.  The  TS-2068 
system    Is    really    stacked    up,    having  a  minimum 


system  configuration  of  344K  with  the  Aerco  FD-68 
or  up  to  424K  with  the  combo  of  LKDOS  and  Ollger 
DOS.  The  main  TS-2068  has  the  (Dan  Elliott) 
modification  to  provide  external  power  for  all 
external  devices  connected  to  the  I/O  port.  This 
modification  was  done  to  the  computer  Itself  and  a 
switch  added  to  the  rear  deck  to  allow  either 
Timex  Power  or  Coleco  Power  to  the  external 
devices.  With  power  supplied  by  the  Coleco  P/S 
the  TS-2068  voltage  reg  Is  protected  from 
overload. 

The  TS-2068  has  five  Disk  Operating  systems: 
1.  Larken  LKDOS,  2.  Ollger  DOS,  3.  Aerco  FD-68 
DOS,  4.  MAX  DOS,  a  combo  of  STACKED  LKDOS  and 
Ollger  DOS,  5.  Stacked  Ollger  DOS  and  SPDOS. 
Actually  there  Is  a  possibility  of  another  by 
having  the  Ollger  DOS,  LKDOS,  and  SPDOS  In  a 
stacked  environment.  SPDOS  Is  the  "Mlllenla  K" 
system  DOS  that  resides  in  RAM. 

The  PRINTING  set  up  allows  either  computer  to 
use  print  buffer  and  either  printer.  This  allows 
different  print  styles  to  be  used  at  the  flip  of  a 
switch.  Also,  the  print  buffer  In  this  set  up 
allows  the  output  data  of  three  computers  to  be 
combined  In  the  print  buffer  for  printing  In  the 
same  document.  Alternate  capability  exists  to 
hook  up  two  QL's  or  two  TS-2068s  as  "computers  A 
and  B",  or  to  hook  up  either  spare  In  the  position 
that  the  Z88  is  shown. 

TELECOMPUTING:  There  Is  a  capability  for 
the  QL  and  TS-2068  to  transfer  ASCII  files  to  each 
other  via  two  modems  and  two  telephone  lines  which 
are  terminated  at  the  computer  desk.  Or,  both 
computers  can  be  downloading  files  from  two 
different  BBS  at  the  same  time.  Much  of  the 
capabilities  have  languished  for  lack  of  time  to 
devote  to  the  tasks.  While  the  entire  system  fits 
nicely  upon  the  "door  top  desk",  there  is  need  for 
side  board  desk  top  space  to  store  disks  and  the 
large  library  of  manuals.  So,  the  computer  corner 
has  wrap  around  desks  In  a  "U"  shape.  The  entire 
floor  space  requirement  Is  about  8X10  feet. 


y-n    7s».*<-r,*>\    /pi*t  cost  Cv 


\  t 

roK  QL  /S  UnVfo  ATM/ft*  *  JT?   *m*L£i~M*J€~i_ 


DO'S  F 


UPDATE  MAGAZINE  ISSUE  DISKS  (MDV) 


The  Issue  Disks  contain  programs  and  utilities  that  are  presented  in  the 
magazine,  plus  some  longer  Softwares  that  are  not  given  in  Update.  All  of  the 
Sinclair  QL  programs  and  some  of  the  TS-2068  programs  are  authored  by 
contributing  programmers.  These  authors  receive  50%  of  the  sales  proceeds.  The 
purpose  of  the  Issue  Disk  program  is  to  encourage  our  programmers  to  continue  to 
produce  software  and  utilities  for  our  support.  We  introduce  you  to  the 
programmers  and  hope  that  you  will  contact  them  directly  to  receive  a  complete 
listing  of  their  products. 

Update  Magazine  considers  each  of  the  centerpiece  titles  of  these  disks  to 
be  well  worth  the  price,  but  we  add  selected  programs  to  the  disks  to  insure 
that  they  are  bargains. 

Sinclair  QL  disks  are  supplied  on  either  Micro  Cartridge  or  5  1/4"  DS  DD  80 
track  Disks.  (If  for  MDV  send  a  Formatted  Cart).  So  far  as  we  know  these  disks 
are  usable  with  any  QL  Disk  Interface  (CST,  Sandy,  Trump,  Cumma). 

TS-2068  Issue  Disks  are  supplied  on  either  40  or  80  track  DSDD  5  1/4",  for 
LKDOS,  Oliger  DOS,  Aerco  FD-68. 


TS-2068  ISSUE  DISKS 

1.  "DAISY.B6"  Disk 

A  Complete  TS-2068  Software 
System.    Data  Base  Management, 
Versatile  Print  Outputs,  Disk 
Management.    Over  20  integrated 
programs • 

2.  "HARTUNG  A"  Disk 

A  complete  set  of  Disk  Mgt 
Utilities  for  Oliger  DOS  Only. 

3.  "MITCHELL  VIEW  CALC"  Disk 
V-C  Expanded  and  converted  for 
DD,  with  Spreadsheet  Printer. 

4.  "DBase-1"  Disk 

Disk  Data  Base  Management. 
For  Records  of  all  kinds. 
Unlimited  size  and  number  of 
Records.    Versatile  Print  Out. 

5.  "1987  Update  Collection" 
"Mail  Merge",  "J-Utilities" , 
Extra  Memory  Utilities. 

6.  "Update  1989  Collection" 
Utilities  presented  in  the 
1989  Update  series. 


SINCLAIR  QL  ISSUE  DISKS  (MDV) 

1.  "CABLE  A-l"  Disk 

The  "HELPER"  Disk  and  MDV  TOOL 
Kit.    Completely  manages  all 
Media.    COPY,  FORMAT,  Read  Files 
Print  Disk  Files,  A  Tool  Kit  for 
for  both  Expanded  and  Stock  QLs 

2.  "CABLE  A"  Disk 

Two  Archive  Expander  Programs 
"REFIELD"  and  "SCAN" 

3.  "CABLE  B"  Disk 
"DBeasy",  an  outstanding  DB 
Software  that  employs  Archive. 

4.  "HARTUNG  COLLECTION"  Disk 
Several  Excellent  Programs 
and  Utilities.     "Address  File" 
"QSO  FILE",  Disk  Utilities, 
and  others. 

5.  "CABLE  C"  Disk 
The  "FILER"  program. 
Plus  added  selections. 

6.  COMING— 
Programs  by  Al  Feng 
Programs  by  David  McCall 


BACK  ISSUES  of  Update  Magazine  are  available  by  year  series  (1987,  1988, 
1989)  for  $18.00  while  supply  lasts. 

SJ 


Software  for  th«  QJu.  that  reallr  Kork* 


We  sail  real  world  software  that  does  real  work  on  a  QL  computer,  much  of 
which  1s  tax  deductible.  There  are  business,  financial  and  technical 
applications.       Most     operate     under     one     of     the     PSION  programa. 

Use  any  of  these  programs  even  If  you're  scared  to  death  of  ARCHIVE0  or 
ABACUS*.  Instructions  teach  what's  really  needed  but  otherwise  they  are 
transparent.       All     are     fully     editable     for     special  requirements. 

Prices  are  from  $9.95  for  QLUTter,  a  resident  boot  utility,  to  $2850.00  for 
a  site  license  for  CAM  MASTER ,  a  friendly  CAD  program  for  circular  came 
that  generates  the  CNC  code  to  a  vertical  mill  controller.  (Get  the  demo 
firsts   It's  only  $9.95  and  really  shows  the  power  of  the  QL . 

Expanded  and  Improved  versions  of  TRUST_FUND  1.3,  MAILBAQ  2.0  and 
QLAND_LORD  1.3  are  available  for  $4.95  with  the  original  medium.  There's 
DBTutor,  a  flash-card  program,  and  DBProgs  with  5  useful  Archive  utilities. 
We  have  The_Transf er_V3,  for  HP  compatible  laser  printing  of  DTP  files  and 
a  range  of  other  useful,  hard-working  software  for  the  wL.  . 

Order     TAX-l-QL/89     by  November  22  to  get  a  $19.95  early-bird  discount. 

PSION**  PC-FOUR  for  MS-DOS  computers    is  only  $99.95. 
(Ever  see  Easel  output  to  an  HP  Plotter?) 

We  create  much  of  our  '  own  software  but  we  market  software  by  other 
programmers.       Please     call/write     for  details  about     our  arrangements. 

Send  for  our  catalogue  which  explaina  things  in  detail. 

&i*1So  ft,   P.O.   Box  8763,  Boston  MA  02114   (617)  8B9-0B30 


 :   fc^ 

Tiro  Stoddard,  85-48  66th  Road,  New  York,  NY 
11374-5212,  writes:  Just  received  a  letter  from 
Pete  Fischer  about  SNUG.  Seems  that  Paul  Holmgren 
is  now  President.  Paul  and  Pete  attempting  to 
pick  up  the  pieces,  along  with  myself  as  the  QL 
and  CPM  Librarian.  I  will  supply  QL  and  Aerco 
PD-68  Public  Domain  software  at  the  cost  of  medium 
plus  postage.  Contact  me  directly  until  SNUG  has 
the  Library  organized. 

There  is  a  National  Sinclair  ECHO  on  Fido 
Net.  Access  via  The  Serial  Port  BBS  (313  286 
0145).  Lastly,  after  reading  QL  Perks  &  Quirks  I 
am  writing  a  series  of  articles  on  QJUMPS  Toolkit 
II.  You'll  be  suprised  at  what  can  be  done-  ready 
in  a  few  weeks.  Tim... 

Thanks  Tim,  will  be  looking  forward  to 
QJUHPS.  Update  always  willing  to  help  SNUG.  Need 
continual  short  news  releases  about  whats  goin  on. 
-BJ_ 


PROMISE  LAND  ELECTRONICS 
Dan  Elliott,  Owner 

Servicing ^gB£SSBSBB& 

electronic  equipment 


Route  1,  Box  117 
Cabool,  MO  65689 
(417)  469-4571 


+  Highly  Rtco*+\t*JeJ &y  t//>Mr&~  fiT? 


Is     thcs     O/C/MATE    20 , 
the  (/LTJMATE 
TS2068  printer? 

USE  MS  AERCO  PRINTER  I/F?  Yes,  if  \ 
an  IBM  parallel  Plug  'n  Print  cartridge  is  used.  \ 

OKI  2Q  FEATURES?  The  OKI  20  can  print  in  ; 
NLS,  draft,  pica,  elite,  fine,  double  width,  italics,  sub/ < 
superscript,  &  underline.  Plain  or  theraai  paper  (tractor/  \ 
friction  feed)  or  acetate  transparencies  can  be  used. 

COLOR  SCREENS  HARD-COPY?  Yes!! 
"COLOR  COPY'  supports  FULL  COLOR**  575  SCREENS  dumps  I  ; 
»PMWT  i  COPY*  features  Hl-tiES  MOPE  coloring  and  copying. 

CUSTOM  CHARACTER  SETS?  Vis,  downline 
loadable  character  sets  of  custom  characters  and  graphics 
can  be  designed  and  transfered  to  an  OKI .20.  The  utility 
software  'OKI  D.L.C.G.'  allows  for  easy  design  of  custom 
char,  sets  and  'OKI  D.L.P.G.'  can  transform  a  portion  of  a 
SCREENS  picture  into  a  downline  loadable  character  set. 

OH  I  MATE  SO  EXPENSIVE?  No,  the  OKI  20 
I  Plug  'n  Print  cart,  are  widely  available  for  about  *1B0. 
Far  a  print  sample,  info,  on  2068  software  for  the  OKI  20, 
and  a  list  of  OKI  20  dealers/prices,  send_a_LSASE  to: 
John  McMichael  ___ 
1710  Palmer*  Dr.  iOKIMATE  tO 
Laramie,    WY  82070  \^SUPPORT 


5-a 


LKDOS  SOFT-WARE 


JIIIHIIIIIWHUL 


iLKDOSh 


MAXCOM  300/1200  baud  Terminal/BBS 

This  full  ftature  modem  software  lata  you  effectlvly  link  tha  modam  to  tha  disk,  so  you  can  upload  or 
download  flits  largar  than  lOOK.Thls  lots  you  sand  NMI  savas  and  larga  taxi  flits  as  wall  as  Basic  or  Coda 
flits,  willed  otlttr  tnodam  programs  couldn't  sand  bacausa  of  mamory  limitations.  Also  flits  can  ba  sant  with 
or  without  b  Information  haadar  (Sptc-ttrm  compotlblt)  . 

It  also  has  a  64  column  display  and  Is  tha  only  2068  modam  program  that  will  run  at  full  1200  baud 
without  missing  charactars.  Othar  faaturas  of  tha  tarmlnal  mod*  ara  IBM  graphic  characters,  auto-dlalar. 
macro  ktys.  110K  disk  buffar  for  capturad  taxt.  auto  rtptat  kays. 

Tha  BOS  Is  tha  most  alaboratt  avallablt  for  tha  2068  and  allows  tha  remote  usar  full  accass  to  tha  disk 
drives  similar  to  a  CPM  BOS,  Features  of  tha  BBS  ara  -  300/1200  baud,  oparallon  with  fast  raponca  avan  at 
1200  baud.    Passwords,  priority  lavtls.  Ust  Hint  limits.    Multlpla  Mtasaga  Basas.  Uploads  and  Oowuloada  ara 
not  Ihnlltd  by  Mtmory.    Dual  Window  Monitor  screen.    Intarupt  drlvan  Hint  out  and  Hangup  protactlon.  Also 
Kttps  a  Uatr  log  of  collars  Namas  and  Activity  on  disk  so  a  printer  lant  naadad  and  Its  aaslly  customlsad  and 
axpandtd. 

MAXCOM  can  bt  ustd  with  tha  2050  tnodam  or  with  tha  Z-SIO  RS232  Intarfaca  and  a  300/1200  baud 
modam.  (a  vtrslon  for  tha  Aarco    flS232  Is  In  tha  works). 
PRICEi  $24.95 


LARKEN  DISK  EDITOR 

This  program  lots  you  axamlna  or  changt  any  byta  on  a  LKdos  disk.  It  Is  usaful  In  rapalrlng  damagad  or 
glltchad  disks,  changing  tha  disk  Nama  or  haad  spaad  ate.  You  can  also  axamlna  tha  track  map  and  disk  Info 
haadars. 

Tha  documantatlon  for  tha  disk  adltor  also  Includas  Information  on  how  to  accass  LKdos  from  Machlna 
Coda  and  Information  on  tha  structura  of  tha  disk  catalog  and  data  blocks. 
PRICE.  $15.00 


SEQUENTIAL/RANOOM  Accass  FILES 

This  utility  Is  a  ram  rasldant  axtanslon  to  tha  LKdos  oparatlng  system  and  lots  you  craata.  raad  from,  or 
wrlta  to  vary  larga  data  flits  kapt  on  disk.  It  usas  tha  commands  OPENS.  CLOSEIl.  PRINT".  INPUTS,  and 
INKEYSH  to  accass  tha  fllas  from  BASIC.  Thara  Is  also  a  high  spaed  search  command  for  finding  a  text  string 
within  the  data  file.  Using  tha  TAB  command,  you  can  randomly  accass  directly  any  record  In  a  file. 

The  utility  Is  easily  used  within  your  basic  programs  and  has  a  lot  of  uses,  from  storing  larga  data  fllas. 
creating  large  spoil  checker  dlctlonarys  or  avan  converting  you  basic  programs  to  an  ascll  text  file  . 

This  utility  lets  you  take  the  limits  off  of  the  data  capacity  of  tha  2068  .Files  on  disk  can  be  huge  I 

A  simple  data  base  program  Is  Included  on  the  disk  to  demonstrate  the  utility. 
PniCEi  $  15.00 


Coming  Soon  from  Larkan  Electronics 

The  Larkan  Oesk  Top  Publisher  «»    Produce  high  quality  printing  (like  this 'page  )  with  an  epaon  compatible 
printer  and  LKdos.  Tha  entire  Hl-res  graphic  page  Is  kapt  on  tha  disk  and  scrolling  though  tha  page  Is  as  easy 
as  clicking  tha  Joystick  or  mouse  on  the  Icon  type  manu.  Taxt  and  Graphic  editing  with  multlpla  sized  fonts 
will  also  ba  featured. 

a*  Spell  Checker  for  Tasword  and  M-Scrlpt  **    This  utility  program  will  let  you  have  your  wordprocassor 
taxt  files  be  checked  by  a  350K  dictionary. 


All  Prices  »US    -  Specify  type  of  drive  when  ordering. 
LARKEN  ELECTRONICS    RR|(2  NAVAN.  ONTARIO  CANADA.,  K4B-1H9 
(6131-835-2680  . 


UPDATE  MAGAZIKE 


□  SPECTERM-64(TS-4„1) 

300/1200  Terminal  Software  lor  T/S2068 
On  -ifi-  AFRCO.  Latktn  *•»<  or  tape. 
Only   S26.00   +   S2.60  S«-H 

ALSO 

□  Z-SI/O  Bare  Boards 

RS-232o  Svrial  Interlace  lor  T/S20$6 

Milh  EBFF  ?QS0  card 
Only   S24.50   +   S2.60  S8.H 

OR  BQIH  FOR  UtfiJC 

*50.00  inc.  S&H 


LARKEN  Disk  Harduare; 
[  j  [MB  Disk  Syslea 

hdude.  LARKEN  Floppy  Dak  hlerlace.  LKDOS  M 
CartrKfce,  Operate*  Menud  and  LKDOS  UWW  DA 
Only   S120.00   4-   S6.00  S&H 

[  1  LKDOS  Cartridge  for  XO 

Sp.ci.Hy  eonliBur.d  LKDOS  W3)  Cartridge  that 
work,  with  your  XO  SAFE  Diek  hardware,  hokidee 
Op*,.**  tal  and  LKDOS  U«W  Dak. 
Only   S6B.OO   +   S3.60  S&H 

[  ]  LARKEN  Rasdisk 

to"  266K  iollik  "rWoMite'lLedak.  E..y  to  km 
..  •  lloppy  di.k  with  LKOOS. 

Only   S60.00   ♦   S3.60  S&H 


[]  Tandon  TM101-4  Quad 
Disk  Drives 

The.e  di.k  drivee  arc  brand  now  in  Uotory 
.ealed  oartona.  Thoy  aro  double  aided, 
doublo  den.ily.  96  to!  (quad*,  lull  height 
drive.  Thev  are  compatible  with  JLO, 
LKDOS,  AERCO  and  OL  diek  eyeteme. 

$45.00   +  *5.00  S&H 

Buy  2.  Q»t  FREE  Driver  Cablot 
Buy  3.  Gal  A\h  for  Hailf  Prioat 
Buy  A,  Get  Q™»  n«lc  Qrjyjc  »=QPE« 

Cabla  {2dr>..S12.60+S2.60  S&H 


Haves  CoBPatible  HODEHS 

[  ]  AvaleK  240O  <3/12/2400>....9H79 
For  CP/M,  OM  and  oilier  tyatenw. 

[  3  AvataK   1200ho  (300/1200)  S99 

For  T/S2068  (w/  Z-SI/O)  and  QL. 

(  ]  Ava1«x  t200<P»  (3O0/t2O0) — $126 
^P=>ock»t  nze  for  tha  Z88. 


I  J  AvataK  t200<E^  (30O/BD0)  S86 

Graat  for  SPECTEFS-r-641 

Epson  Coapatible  PRINTERS 

t   ]  SaiKoaha   1200AI  <120/2B)..»199 

|    3    Saiko.ha    180AI  (100/20)..S169 

t    3   Star   NXIOOO  (144/34)....»229 

All  modem,  add  $3.60  lor  S&H.  .«  erbWre  add 
$10.00  lor  S&H  (Canada  double  S&H  on  al  ileae). 


(Bee 

90306 


Ed   Grey  Enterpri 

P.O.    Box    *2186,    Inglewood,    CA  t 

hfo  »  213-759-7406  «  Order 
faff  Jk$  Qny  Mkr  IBS  4  MP/9  im-S7H260)_ 


We  provide  continuing: 
support  for  the  TS-2068 
Users.    Our  specialties 
are  Telecom  Modems, 
Z-SI/O  Interface, 
Printers,  and  Disk 
Drives  for  both  the 
TS-2068  and  the  QL. 
Call  for  your  special 
needs.    Use  our  BBS  for 
keeping  updated  about 
Sinclair  Computing-, 
Shopping-,  and  Message 
traffic.    Ed  Grey. 


The  Cambridge  Z88  Portable  Computer 


DOM I MO 


CUBEB 


NEW  YPRK 


212  «P 
39th  £3 
CITY  Aft't^J, 


PRESIDENT  MIKE  FINK 


AT     #4BB|  THEN 
EACH     a>  1  tDO)     WORTH     OF  RELATED 
tIBS     YOU     ORDER  — 8TOPB     AT  »42E 


G  E 


S,  X 


1  *? 

•zto 

2  1 
22 
23 
2-* 
29 


-rue:    z-bb    portable  computer 

32K     RAM     OR     ERROM  CARDS. 
1 2BK     RAM     OR     EPROM  CARDS. 
T>  X  2K     RAM     CARDS  w 
PARALLEL      PRINTER     CABLE  . 
SERIAL     RR INTER     CABLE  (a) 
RC     LINK         ...       ISM  .... 

RC     LINK  ...       MACINTOSH  - 

RC     LINK         .       .       _      QL -  .... 

. ERROM     ERASER     —      2     CARDS  - 
.  ERROM     ERASER     —     "»     CARDS  . 
.  A  /  C     ADAPTER  «       2— OS.      WALL - 
,  A  /  C      ADAPTER  «       2— OS„       CAR      -  _ 
,  MY     MANUAL      "A"    P REE   WITH  Z— B6 
,  MV     MANUAL      " D "  .       _       .       .  . 

,  SQUARE     RIN     PRINTER      1  3=5  CRS 
SOU  ARE     RIN     RR  INTER     TOftV  CRS 
■  PORTABLE  I    I  MK  —  J  ET     RR  I  NTER     iflj.  CPS 
, CARRVINS     CASE     "A"  .... 

,  CARRY  I  N 13     CASE      "  S  "  .... 

.  202K     PORTABLE     DISK     DRIVE  •*• 
2»     MR.      AA     BATTERIES      <  > 
<*G9     MR.      AA     BATTERIES      <  -f-  > 
,53     NI— CAD      *C-      BATTERIES  - 
.  12001     BAUD     MODEM     PKQ         .  *  _ 

3  .  S  "     DISKS.       1  CT»     RACK  ... 
.RIBBON— RILM     C130BK     RR I NTER 
.  INK-JET    INK,     PLAIN  or    INK-JET  . 
. INK— JET     STAND  ...... 

COLORED      INK      <  R  — 13  —  B  >  .... 


*P=5 
3*7=5 
tf»2 


a  l  a> 
a  2iv 

»7da) 


3  -  "7" 
X  S 


DELIVERY     UNLESS  YOU 
PR  I  NTER  r      THEN     ADD     *  1  ES 


THE     ONLY     DEALER     IN  THE 
WORLD     WHO     GIVES     YOU  AN 
UNDERSTANDABLE  BEGINNERS 
INSTRUCTION.  -MANUAL ! !  AND 
THE    ONLY    DEALER  BELLING 
AN      AFFORDABLE  EPROM 
ERABER,     AND  THE  PLACE  TO 
BUY     THE     PORTABLE  DISK 
DRIVE     TO     BAVE     LOADS  OF 
MON9Y,   FREE  LOTTO  PROGRAM 
WITH  Z-BB  PURCHASE.  ALSO 
THE     ONLY   - PERSON     ON  THE 
PLANET     WHO     CAN  SHOW  YOU 
HOW  TO  COLLATE ,    AND  PRINT  , 
MULTIPLE  COPIES  OF 
MULTIPLE  FILES  EASILY! ! ! 
HHXLE     YOU     ARE  ASLEEP  OR 
AT  THE  MOVIES// 

efb       *       V       ♦       ♦       4&  V 

ALSO,       THE     PNLY  PERSON 
OFFERING     PROGRAMS     ON  s 
CHEAP     DISKS! !     THEY  WILL 
COST     BETWEEN  tl0  AND  *40 

*  v    ♦    ♦   ♦  v 

THE  ONLY  PLACE  TO  GET  CAR 
AC  ADAPTERS! 

*  ^    v    ♦    *    ♦  V